PoetGrant's Press

Inside the Mind of PoetGrant

Bash Blog Rocks

May 07, 2019 — Grant Ford

I have been using Bash Blog for a few months now. Only recently have I transferred this blog to Bash Blog because I have finally configured it in such a way that makes me all happy and warm inside. There are a few more tweaks that I need to make, and one huge overhaul of the script that I would like to make. The tweaks are simple CSS properties, but the overhaul is to rewrite the HTML portion and CSS portion so that it is compliant with HTML5 standards.

Let me just run through some of the highlights of this wonderful little piece of software.

HTML and Markdown

Although I use HTML because my muscle memory is more adept to typing out the little tags, it is something of a wonder that this little script can also convert Markdown into HTML content on-the-fly. Markdown is a simple way to write a blog and an easy way to just start writing without the hassle of remembering HTML tags and constantly checking the W3C School website for how to style or write your content. With Markdown support, Bash Blog ends up being extremely accessible to just about any user that can read the README file on GitHub.

Easily Modified

Bash Blog is, I think might be obvious, written in bash script. Now, I don't actually know bash (as many of you know, I am more of a Python guy), but bash scripts are fairly easy to read and thus fairly easy to intuit modifications. For instance, I removed all mention of Twitter, Disqus, and Google Analytics from my version of the script, which removed a pretty sizeable portion of the code. These are things that I don't really need, and frankly don't see as necessary for a website to function properly.

My next modification will be to change all of the XHTML1.0 doctypes to HTML5, and to remove the placeholder text in a new "post". HTML5 offers a great many advantages over the other versions, and I would like to utilize it accordingly. I have also grown accustomed to elements that are more human readable in the newest version of HTML, so I think this will be a good change. In the process, I will undoubtably learn a little Bash scripting, so it is win win in my book.

Another advantage to this ease of modification is that it will allow my to use tags that I am more familiar with. Instead of a div tag that describes a specific element that ends up being simply the content, I would like to just use the article tag from HTML5 and let the style sheet deal with just one element and its child elements. I know it is an odd thing, but it just seems cleaner to me to do it this way.

Speaking of books, I have been writing my book in a format called ASCIIDoc and I think it would be pretty fantastic if the script also supported that, but that will be a huge stretch goal for this little project of mine.

Less Confusion for Me

Bash Blog also is much less confusing to me than other static site or static blog generators. I love Pelican, but I always had trouble with the themes and I simply didn't want to have to figure it out when I could just write the CSS myself. Bash Blog only references an external style sheet for CSS, so all you have is one file to modify, which works much better for me than modifying four seperate style sheets and then making sure it's all conformant to Jinja and the generated HTML of Pelican. So this one is a win in my book.


This article is not comprehensive, but I hope I outlined some pretty neat features that it includes. I also hope that you see why I love this project, because it is super easy to use and modify. I would recommend even the stanchest users of other platforms to just give it a try and see if it can fill a need without all the bells and whistles of other static site and static blog generators.

If you want to contact me, you can find me at @poetgrant on Mastodon or send a message to me on Matrix. My username there is @poetgrant:librem.one.