What is old, is new again!

Journey

A couple of decades ago I used to hand-write HTML pages. Then came scripting langauges and databases which made had-written HTML obsolete and tedious. GUI and dynamic nature of the CMS like Wordpress was great, but it came with a pain of consntantly updating and securing the site. My blog was hacked by script kiddies more than once due to an older version of PHP or Wordpress.

Using cloud based service is a good alternate, but I felt like trying something different. I moved my blog to Hugo. It is a static site generator written in Go and is pretty fast to generate the entire statis site in miliseconds. As the site gets bigger, it might take longer to generate it, but I’ll worry about scaling when I have to. I write my posts in markdown, which is way simpler than HTML and Hugo generates the HTML pages and all the supporting pages like pagination, index directories, etc.

Initially I planned to host the site on S3 or R2 (by Cloudflare), but found that Cloudflare has a pretty good support for Hugo with its Pages product. Pages also has a generous free tier, which helped make the decision easier.

Workflow

  • Write posts in markdown
  • Push them to Github repo
  • Cloudflare Pages triggers build and deploy the site based on the Git branch
  • A few seconds later my whole site is updated on my domain

Tools

  • Static Site Generator: Hugo with backup on GitHub.

  • Hosting: Cloudflare Pages.

  • Editor: I use Zed editor to write my posts. Zed replaced my old favorite Sublime Text. It integrates with OpenAI API & GitHub Co-pilot pretty well.

  • Hugo Theme: I use a simple and clean theme called PaperMod.

Got a comment or feedback? Email me here or @ me here.