No commit activity in last 3 years
No release in over 3 years
A Jekyll plugin to generate custom category index pages. Bring your own template.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.9
~> 3.2.0
~> 10.0

Runtime

~> 2.5.3
 Project Readme

Jekyll::Categorizer

A jekyll plugin to generate category pages using your own template.

Install

Add jekyll-categorizer to your site's Gemfile under the jekyll_plugins group:

group "jekyll_plugins" do
  gem "jekyll-categorizer"
end

And then execute:

$ bundle install

Usage

Configure in _config.yml the following settings:

jekyll_categorizer:
  namespace: categories # this will be used for URL namespacing (E.g. /categories/foo)
  layout:    category   # this should be your own layout

and lastly, in your specified layout, make use of the following snippet:

# ...
{% for post in site.categories[page.category] %}
# ...
{% endfor %}
# ...

To iterate over every category post. This should build a category page for every category found in your articles under _posts.

E.g. If you have a category foo then you'd be able to see every post for that category under /categories/foo.html (using categories namespace)

License

The MIT License.

Contributing

Check Code of Coduct.

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request