I bet the first question I will get when I tell someone that I built my own blogging engine will be "Why did you waste your time doing that? There are dozens of blogging engines already out there." It seems apropos that one of my first articles should answer that question.
Why not? Is learning bad?
When I first thought of making my own blog I had one requirement in my mind that I knew I was not going to stray from. The blog had to be static. I did not want to have to worry about setting up a complex and/or expensive hosting solution for my blog. I knew that if I had static HTML files with minimal CSS I could serve up hundreds of thousands of page views from the most spartan of virtual private servers (VPS). I could also migrate between VPS with ease if I had to scale up for any reason.
With this requirement set in stone I set about looking at possible blogging engines I could use. Having first heard about static blogging engines from Marco Arment I took a look at his open source engine SecondCrack. After a bit more research Jekyll and Middleman jumped out as the go to open source blogging engines. After prodding around their documentation I realized that I had absolutely no idea how one of these blogging engines worked under the hood. Rather than spending hours reading documentation, deploying my blog and then finding a shortcoming that I would have to work around I decided to build everything from scratch so the only thing blocking myself could be me.
There seems to be a fear nowadays of building anything from scratch. To most programmers it is easier to stitch together random packages packages from RubyGems or npm and call it a day instead of trying to understand how they are implemented. While we are standing on the shoulders of giants for a number of things in computer science, most of the problems we encounter on a daily basis are not so complex that we can't build the solution ourselves.
I am not trying to make the defacto blogging engine for anyone. Hell I don't think anyone other than myself will ever use this engine and that is the point. When I started typing my first lines of Object-Oriented Turing in high school 17 years ago, I was not trying to build some amazing program to change people's lives. I literally had no idea what I was doing but enjoyed every second of trying to figure out why something worked. I had that exact same feeling again while trying to create this blog.
As an iOS developer I am very keen on Apple's Swift programming language. I use Swift on a daily basis for all of the iOS apps I build and love the idea of using Swift as a scripting language for my blogging engine. Because there is not as much open source Swift code as say Ruby, Python or Node.js it would also force me to learn even more because I wouldn't be able to fall back to any RubyGems if the going got tough.
While I did use Ruby to get this blog up and running as quickly as possible the engine has been built in a very modular way so that I can slowly replace pieces of it with Swift until I have migrated the entire engine over.
I am a huge video game fan. I have owned basically every console since the Nintendo 64 and I always wished I had written down what I had thought about all the games that I have played over the years. One of the main reasons I wanted my own blog was for that exact reason. I wanted to write detailed accounts for games as I was playing them so a decade from now I could go back and see if I really did think that game was the greatest of all time or if was simply rose-colored glasses.
If I built my own blogging engine that I could easily add metadata that would allow me to track about how I felt about these games and allow myself to review them empirically. With all that data I could create custom pages to show my favourite games of the year, my favourite genres, the greatest of all time. Who knows but the possibilities are endless and all because I have complete control of how the information is stored and consumed.
A journey of a thousand miles begins with a single step
While I am sure I could have gotten my blog operational in half the time with a ton more features if I used an existing blogging engine (I still don't have an RSS feed for example) I already have a dozen features planned out and couldn't be more excited about implementing them. I barely have an idea of the exact implementation details and honestly that is half the fun right there. It's not the destination I am focused on but the journey and I got a long and winding one ahead of me.