# \[solved\] Only one post read from \_posts

**URL:** <https://talk.jekyllrb.com/t/solved-only-one-post-read-from-posts/7202>\
**Category:** Help\
**Created:** [April 6, 2022, 4:11pm UTC](https://talk.jekyllrb.com/t/solved-only-one-post-read-from-posts/7202 "2022-04-06T16:11:48Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![BastienDurel](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/bastiendurel/32/4543_2.png) [@BastienDurel](https://talk.jekyllrb.com/u/BastienDurel)\
**Post date:** [April 6, 2022, 4:11pm UTC](https://talk.jekyllrb.com/t/solved-only-one-post-read-from-posts/7202/1 "2022-04-06T16:11:48Z")

</div>

Hello. I’m new to jekyll and have a problem with posts : only the las one (by name’s date) is considered by the builder (4.2.2)

I have the 2 files in \_post:

```auto
$ ls -l _posts/
total 8
-rw-r--r-- 1 bastien bastien 1571 6 avril 16:23 2022-04-05-c-est-reparti.md
-rw-r--r-- 1 bastien bastien 1580 6 avril 16:52 2022-04-06-le-cinquantieme.md

```

during build --verbose, I have a line for the first one ; but not for the second :

```auto
      Generating... 
           Reading: /_layouts/default.html
           Reading: /_layouts/home.html
           Reading: /_layouts/page.html
           Reading: /_layouts/post.html
       EntryFilter: excluded /Gemfile.lock
       EntryFilter: excluded /.jekyll-cache
       EntryFilter: excluded /Gemfile
           Reading: _posts/2022-04-05-c-est-reparti.md
           Reading: _posts/2022-04-05-c-est-reparti.md
           Reading: festival/historique-du-festival.md
           Reading: festival/cioff.md
[...]

```

if I move the second to be “before” with `mv _posts/2022-04-06-le-cinquantieme.md _posts/2021-04-06-le-cinquantieme.md` ; then the build only read it :

```auto
       EntryFilter: excluded /Gemfile
           Reading: _posts/2021-04-06-le-cinquantieme.md
           Reading: _posts/2021-04-06-le-cinquantieme.md
           Reading: festival/historique-du-festival.md
           Reading: festival/cioff.md

```

… but the 2022-04-05-c-est-reparti.md is ignored.

[strace show](http://ix.io/3Ut8) both files are stat’ed, but only one is opened

Can anyone give me a pointer on how to make sure all files are processed ?

The source files can be seen here : [\_posts · master · Bastien Durel / sacres · GitLab](https://git.geekwu.org/bastien/sacres/-/tree/master/_posts)

BTW: with a third file, only the first is seen, it’s not a 2-files only problem 😕

---

<div class="post-metadata">

**Author:** ![BillRaymond](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/billraymond/32/5963_2.png) [@BillRaymond](https://talk.jekyllrb.com/u/BillRaymond)\
**Post date:** [April 6, 2022, 5:24pm UTC](https://talk.jekyllrb.com/t/solved-only-one-post-read-from-posts/7202/2 "2022-04-06T17:24:33Z")

</div>

Not quite sure what is happening here. Can you check the title and dates in the YAML front matter for both files and make sure they are not identical? I’m wondering if you copied and pasted, then only changed the filename without modifying the front matter?

If my first theory is wrong, could you share the contents of both files and or share a link to your repo, if it is public?

---

<div class="post-metadata">

**Author:** ![BastienDurel](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/bastiendurel/32/4543_2.png) [@BastienDurel](https://talk.jekyllrb.com/u/BastienDurel)\
**Post date:** [April 6, 2022, 5:39pm UTC](https://talk.jekyllrb.com/t/solved-only-one-post-read-from-posts/7202/3 "2022-04-06T17:39:53Z")

</div>

The dates are in sync with the front matter.

The repo is here : [\_posts · master · Bastien Durel / sacres · GitLab](https://git.geekwu.org/bastien/sacres/-/tree/master/_posts)

---

<div class="post-metadata">

**Author:** ![rdyar](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/rdyar/32/710_2.png) [@rdyar](https://talk.jekyllrb.com/u/rdyar)\
**Post date:** [April 6, 2022, 5:43pm UTC](https://talk.jekyllrb.com/t/solved-only-one-post-read-from-posts/7202/4 "2022-04-06T17:43:41Z")

</div>

is it date related? today is the 6th, try putting the date as something in the past like the 5th.

---

<div class="post-metadata">

**Author:** ![BastienDurel](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/bastiendurel/32/4543_2.png) [@BastienDurel](https://talk.jekyllrb.com/u/BastienDurel)\
**Post date:** [April 6, 2022, 6:45pm UTC](https://talk.jekyllrb.com/t/solved-only-one-post-read-from-posts/7202/5 "2022-04-06T18:45:25Z")

</div>

I tried the 5th, the 4th. I also tried to change the year to 2021.

---

<div class="post-metadata">

**Author:** ![rdyar](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/rdyar/32/710_2.png) [@rdyar](https://talk.jekyllrb.com/u/rdyar)\
**Post date:** [April 6, 2022, 6:53pm UTC](https://talk.jekyllrb.com/t/solved-only-one-post-read-from-posts/7202/6 "2022-04-06T18:53:39Z")

</div>

did you stop and restart jekyll? not sure that would be needed but you never know.

what if you remove the date from the front matter?

---

<div class="post-metadata">

**Author:** ![BastienDurel](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/bastiendurel/32/4543_2.png) [@BastienDurel](https://talk.jekyllrb.com/u/BastienDurel)\
**Post date:** [April 6, 2022, 7:08pm UTC](https://talk.jekyllrb.com/t/solved-only-one-post-read-from-posts/7202/7 "2022-04-06T19:08:04Z")

</div>

I re-started. I removed \_site. I ran jekyll clean.

Removing the dates from front matter does not change anything.

---

<div class="post-metadata">

**Author:** ![fabiomux](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/fabiomux/32/2656_2.png) [@fabiomux](https://talk.jekyllrb.com/u/fabiomux)\
**Post date:** [April 6, 2022, 8:04pm UTC](https://talk.jekyllrb.com/t/solved-only-one-post-read-from-posts/7202/9 "2022-04-06T20:04:38Z")

</div>

After some brute force debugging I found the guilty in the ‘jekyll-language-plugin’ gem.  
In the `Gemfile`, just put an `#` symbol on that line and build & serve the project again

```auto
group :jekyll_plugins do
  # This below is the line to comment
  #gem 'jekyll-language-plugin'
end

```

Probably that gem hasn’t been configured and introduces some mistakes in the building process.

---

<div class="post-metadata">

**Author:** ![BillRaymond](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/billraymond/32/5963_2.png) [@BillRaymond](https://talk.jekyllrb.com/u/BillRaymond)\
**Post date:** [April 6, 2022, 8:16pm UTC](https://talk.jekyllrb.com/t/solved-only-one-post-read-from-posts/7202/10 "2022-04-06T20:16:29Z")

</div>

@fabiomux Ha! I was just posting that and yes we both came to the same conclusion. However, I do not believe it is the plugin, but the use of the `group` element in the `gemfile`. Here is how I fixed the problem:

Change this code in the `gemfile` from this:

```auto
group :jekyll_plugins do
  gem 'jekyll-language-plugin'
end

```

To this:

```auto
gem 'jekyll-language-plugin'

```

Make sure you re-run `bundle exec jekyll serve --livereload`.

If that does not work, delete the `gemfile.lock` file, run `bundle install`, and then run `bundle update`. Then, try running `bundle exec jekyll serve --livereload` again and you should see all posts.

---

<div class="post-metadata">

**Author:** ![fabiomux](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/fabiomux/32/2656_2.png) [@fabiomux](https://talk.jekyllrb.com/u/fabiomux)\
**Post date:** [April 6, 2022, 8:49pm UTC](https://talk.jekyllrb.com/t/solved-only-one-post-read-from-posts/7202/11 "2022-04-06T20:49:35Z")

</div>

As mentioned here: [Plugins | Jekyll • Simple, blog-aware, static sites](https://jekyllrb.com/docs/plugins/installation/) the _jekyll\_plugin_ group forces to load the wrapped gem at the beginning, putting the gem outside it won’t be loaded unless explicitly configured (I suppose the docs is talking about the _:plugin_ section).

So in that case, having no setup in the _\_config_ file, removing the gem from the group should be the same as commenting on it inside the group, but I haven’t investigated further.

---

<div class="post-metadata">

**Author:** ![BastienDurel](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/bastiendurel/32/4543_2.png) [@BastienDurel](https://talk.jekyllrb.com/u/BastienDurel)\
**Post date:** [April 7, 2022, 6:11am UTC](https://talk.jekyllrb.com/t/solved-only-one-post-read-from-posts/7202/12 "2022-04-07T06:11:51Z")

</div>

Thanks a lot !

I removed the jekyll-language-plugin from the plugin list as it didn’t do what I wanted to do, but I wasn’t aware it can have an effect if left in the Gemfile …

I copied the `jekyll_plugin` group config from a documentation without knowing its effects 😕
