In writing for this blog, there are some posts I'd like to write that I don't think quite fit the theme of this blog. For example, I want to write short book reviews to link to from my books page, but I don't want them showing up on the index page and archives. I like having those pages be focused on more technical topics, at least for now.

Introducing ramblr.

One piece of inspiration for this is the blog You Might Find Yourself. I want somewhere I can put comments about links, book reviews, and (some) posts that aren't my usual technical writeups. Currently, I have a good backlog of posts I want to finish. That isn't always the case, though, and I'm hoping these less technical posts keep me in the habit of writing and posting.

I am using Pelican's hidden_articles feature to hide these articles from the index page and archives. I created a new page, ramblr.html to act as a secondary index page for them. This code is a heavily edited version of what was at index.html in my theme.


{% extends "base.html" %}
{% block content_title %}
{% endblock %}
{% block content %}

{% if hidden_articles %}
{% for article in hidden_articles %}

<section id="content" class="body">
    <ol id="posts-list" class="hfeed">
            <article class="hentry">
                    <h1 class="entry-title"><a href="{{ SITEURL }}/{{ article.url }}">{{ article.title }}</a>

                <div class="entry-content">
                    {% include 'article_infos.html' %}
                    {{ article.summary }}
                    {% include 'comments.html' %}
                </div><!-- /.entry-content -->
</section><!-- /#content -->

{% endfor %}

{% endif %}
{% endblock content %}

I also had to update pelicanconf.py with:

DIRECT_TEMPLATES = ['index', 'authors', 'categories', 'tags', 'archives', 'ramblr']

Without this, ramblr.html doesn't generate. If I just add ramblr, all of the other templates don't generate.

Eventually, I might move my ramblr posts to a category or tag, but that requires a lot of fiddly excluding on the index and archives templates and rewriting the categories or tags page to not inherit from the index (or to only inherit for the other categories/tags). I also am not as consistent or structured as I would like to be about categories and tags so I'd like to get those more settled before moving ramblr to one of those.