Custom Error Pages in Hugo
Hugo is a well known static-site generator, which is what I’m using to generate this website. I also like to have a custom error page for different HTTP errors, such as 404, 403, etc., and I like them to be in the same style as the rest of the website.
Read more →Switching to Hugo
After a few years of silence on the blog front, I tried to switch my website to use HTTPS everywhere. However, the existing Middleman based website had references to insecure HTTP resources, which caused a blanket switch to HTTPS to cause the site to fail to load correctly.
Read more →Why programming is so hard
While a computer is simply a machine that takes in a series of instructions and executes them in order, most people have a hard time understanding this fact. As Arthur C. Clarke wrote
Any sufficiently advanced technology is indistinguishable from magic.
My observations from my own experiences appear to stand as evidence of the above statement.
Read more →Metaprogramming in Ruby
in Code Code, Ruby, Metaprogramming
Recently, I developed a configuration DSL that would populate a database. I found myself writing a lot of repetitive code to handle the DSL syntax, and thought that this would be a good case to programatically generate the methods.
Read more →