sina.ahmadi@insight-centre.org
Read more about the Jekyll philosophy.
_post
, _includes
and other files_site
ready to be served by Apache, Nginx or other web servers.permalink
structureA basic Jekyll site usually looks something like this:
.
├── _config.yml
├── _data
| └── members.yml
├── _drafts
| ├── begin-with-the-crazy-ideas.md
| └── on-simplicity-in-technology.md
├── _includes
| ├── footer.html
| └── header.html
├── _layouts
| ├── default.html
| └── post.html
├── _posts
| ├── 2007-10-29-why-every-programmer-should-play-nethack.md
| └── 2009-04-26-barcamp-boston-4-roundup.md
├── _sass
| ├── _base.scss
| └── _layout.scss
├── _site
├── .jekyll-metadata
└── index.html # can also be an 'index.md' with valid front matter
_config.yml
Once Jekyll is installed, you can create your new blog with the following command:
jekyll new YOUR_WEBSITE_NAME
Which will generates a folder with the following structure:
YOUR_WEBSITE_NAME/
.gitignore
_config.yml
_includes
_layouts
_posts
_sass
about.md
css
feed.xml
index.html
Anywhere that can serve static pages including:
“ When Jekyll is used alongside GitHub, it will automatically re-generate all the HTML pages for your website each time you commit a file.”
Nota bene: GitHub Pages does not support server-side languages such as PHP, Ruby, or Python.
Github does not allow any but a few specific plugins to run for security reasons 🤷🏻♂️
Learn how to create your own themes here.
There are three types of GitHub Pages sites:
<user>.github.io
<organization>.github.io
You can only create one user or organization site for each GitHub account.
Gemfile
A Gemfile
is a list of gems required for your site.
source "https://rubygems.org"
gem "jekyll"
group :jekyll_plugins do
gem "jekyll-feed"
gem "jekyll-seo-tag"
end
Bundler installs the gems in your Gemfile
bundle install
to install the gemsbundle exec jekyll serve
to build your siteIf you’re not using a Gemfile
, you can just run jekyll serve
jekyll serve
gh-pages
or master
branchjekyll-scholar does it wonderfully, but not supported by Github Pages.
A wordaround: Converter from BibTeX to html
Any questions? 🙂