Posting With Hugo
Switching to Hugo caused a major change in the workflow behind the site.
Wordpress comes with a full-featured backend which allows you to manage basically your entire website (if it’s Wordpress powered), but Hugo don’t. There’s no-backend admin site nor an webeditor to create and manage your posts. It doesn’t bother me. It’s a completely different workflow and I’m starting with a rough minimum flow initially untill I get a bit more expirence running Hugo.
The first workflow…
To manage the site I’ve created a Git Repositoriy. Here I have all site setup and configuration - and all content for the site. Checking out this repository on any computer with Hugo installed will allow me to instantly to spawn a local testsite running on the computer I sit with (as Hugo has this feature build in).
Posts a written in Markdown. Initially I wrote the firsts posts in any basic text editor - Visual Studio Code, Notepad or Atom. It works, and as I rarely use advanced formatting of any kind, learning sufficient Markdown is easy.
Right now I’ve started playing with a few different markdown editors. I haven’t found a perfect editor yet, but the initial testing of a few different markdown editors suggest, that an editor can bring a lot of the nice visual editing from wordpress back.
As an added bonus, the content can be committed to the Git repository as a working draft and not published until it’s ready (Hugo has a draft state which will prevent the posts from being public).
Publishing is a matter of running hugo (without parameters) which build the site. It basically generate all content of the site (html files, images, css files and everything else) in a single folder (it currently takes less than a second), and rsync the contents of the generated folder to the server running the site itself.