Static Sites with Jekyll

Jekyll Pages

This site serves as a small example and source of documentation on how to get started with a static site at TRIUMF. Much of the documentation on this site is just a distillation on what can be found from the official Jekyll docs and/or from the documentation for the current theme being used here along with its styling. In case of confusion, you may want to refer to those documents, or you can send your question(s) to me over email to dthomson at triumf.ca.

If you have corrections or additions that you’d like to add, please fork this project and send a merge request with your proposed changes.

Latest Posts

Enabling Pagination

One you’ve started adding many different posts to your site, you may want to help people navigate through a manageable list of entires at a time. Jekyll comes with a pagination plugin that can help you limit the number of posts you publish per page. Note that the pagination plugin only seems to work for a single collection, so if you’re using multiple collections, you may not be able to paginate all of it (with the plugin at least).

Creating Additional Collections

Normally Jekyll expects to only manage files built in your _posts directory as a collection of individual pages to be generated for display on a given site. In some cases, you might want to provide multiple sections of your site that can have ‘posts’-like behaviour without being actual blog posts. For example, a site may have separate news, publications and job posting sections that all get updated with a new entry as needed.

Welcome to Jekyll!

You’ll find this post in your _posts directory. Go ahead and edit it and re-build the site to see your changes. You can rebuild the site in many different ways, but the most common way is to run jekyll serve, which launches a web server and auto-regenerates your site when a file is updated.