Hugo Blog Workflow
Finally get my Hugo Blog workflow iron out.
Ghost, Hugo and Markdown
Early 2017 I switched my blogging package from WordPress to Ghost.
I was attracted to Ghost due to its simplicity, low resource requirement, and most importantly the markdown syntax.
I started using markdown with GitHub. Nowadays I create all my documentation, notes in markdown. Typing them up in VSCode, I don’t need the web GUI interface in Ghost.
Late last year I come across the term
static site generator. After experimenting with different packages, I picked Hugo.
Hugo is a command line tool. There is no online/web GUI. It does have a steep learning curve during initial setup. However once I lock down my directory structure, theme, and all the commands I need, it become smooth and easy.
Following is the workflow in plan commands:
Create skeleton markdown file.
cd <blog dir> hugo new blog/<new-postname>.md
Edit blog post in VSCode.
Test in browser
hugo server -D
Publish to web server
hugo rsync --stats -haz --delete public user@host:/home/user
I put the publishing steps with a few enhancement into my zsh function:
It is always a pain to pick a new theme when switching packages. I finally settle on the current one, and modified it with AdSense. Following are the original and my fork:
The switch gives me a chance to review my blog writing, technique and post structure. It was a good experience, but not sure if I want another one anytime soon.
Also check out my automation setup: Jenkins Blog Automation.