Octopress, by default, generates static websites with a
/blog prefix attached
to categories, archives and post URLs. This is particularly annoying when the
blog is hosted at
blog.yourdomain.tld and have funny URLs like
To get rid of this, I’ve created a clone of the
classic Octopress theme with the necessary changes. It also renames
Home in the navigation bar.
To install and use
1 2 3
Changes are also required in
pagination_dir properties have to be modified to remove the
1 2 3 4 5 6 7 8
After installing the theme and fixing
_config.yml, generate the blog.
DIY for other themes
To achieve this for other themes, the following modifications should suffice. [Assumption: The theme is already installed and you are familiar with diffs]
archives folder from
source/_includes/custom/navigation.html to fix navigation URLs.
1 2 3 4
source/index.html to fix the Archives page URL.
A theme in the
.themes folder can be modified similarly, but will have to be
reinstalled with the
rake install['theme-name'] command afterwards.