jandecaluwe / urubu

A micro CMS for static websites, with a focus on good navigation practices.
urubu.jandecaluwe.com
GNU Affero General Public License v3.0
179 stars 36 forks source link

tag/index.md makes pagers disappear for certain folders #61

Open isacdaavid opened 7 years ago

isacdaavid commented 7 years ago

I faced this problem while configuring a custom Urubu website, but here is how you reproduce it using the default project:

  1. Create a top-level folder called log ---I wanted to use that name instead of blog--- and put an index and some posts inside; or just copy from blog
  2. Enable pagers in those posts, add some tags to their front-matters.
  3. Create a top-level tag directory to enable tags, and make sure to drop an index.md in there. I'm simply using:

---
title: Tags
layout: index
order: title

---

Then Urubu (1.2.0) will stop generating pagers for pages inside log

jandecaluwe commented 7 years ago

I followed the scenario but I cannot reproduce this issue. I still see pagers as expected.

On a sidenote, ordering directives in the tag folder are ignored; content is ordered according to the content of tag objects.

isacdaavid commented 7 years ago

I think I managed to debug my way through this issue:

The make_pager() function is returning as soon as it finds a content-less directory in the project navlist object. This could be the /tag/ directory or any other; and ensuing directories won't get processed no matter their contents.

Does that make sense to you? I'll share my trivial fix in a moment...

isacdaavid commented 7 years ago

I apologize for any potential disturbances. The previous identical request was closed by accident.