Skip to content
hsseung edited this page Feb 7, 2017 · 3 revisions

Welcome to the cos495.github.io wiki!

Jekyll is used to transform markdown into static HTML. We are using the default minima theme provided by Jekyll. To publish a new blog post, you place a markdown file in the _posts subdirectory of the repo, commit and push, and Github Pages will automatically rebuild the site.

If you're on the teaching staff, you should install jekyll by following these instructions. Then git clone this site, cd into the directory, and start the local server with a command like this:

$ bundle exec jekyll serve --watch --port 4444 --drafts

Point your browser at http://localhost:4444 and you should see your local version of the site. I specify port 4444 in the bundle command but you can leave this out if you are satisfied with the default port of 4000. The --drafts switch makes the posts in the _drafts subdirectory visible on the home page. Now you can make changes to the site and check them on the local server. Once you're satisfied, you can commit and push to github, and the changes will appear at cos495.github.io.

Notes on customization:

schedule.org gets exported to schedule.html, which is manually edited to create schedule.md I do this because it's convenient to edit schedule.org in Emacs org-mode. jQuery is used to apply yellow and red shading to certain rows.

_layouts/default.html contains JavaScript to load mathjax and define TeX macros. It should be possible to define the latter in the markdown file, but somehow kramdown is messing it up. I had to add the other files in the _layouts directory from the minima theme, even though they are unchanged because otherwise the site fails to build on Github Pages (although it builds fine locally).

Clone this wiki locally