Summary
Static site generator. Uses markdown format as source.
Run local server
From the directory that contains the hugo project, e.g. “/mnt/data/Dropbox/emacs/hugo/braindump”
cd /mnt/data/Dropbox/emacs/hugo/braindump
hugo server --config config.yml # to select the config file to build the project and run
# in side netlify.toml, file build command
command = "hugo --gc --minify --config config.yml"
Documentation
Getting started with a theme
e.g.: https://github.com/gethugothemes/liva-hugo
git clone git@github.com:gethugothemes/liva-hugo.git
# cd in the project directory
$ cd liva-hugo/exampleSite/
# Start local dev server
$ hugo server --themesDir ../..
To use `hugo server` command, copy the theme to “themes” directory: ``` copy-example-site-here themes/live-hugo ```
Editing layouts
Issue I faced with my brain dump
The list view was appearing, I disabled the
profileMode:
enabled: false
title: PaperMod
in `layouts/_default/list.html` it checks for this variable to render list. details about templates here
Ordering list
in the list.html
{{- range $index, $page := ($paginator.Pages.ByParam "lastmod").Reverse }}
enableGitInfo: true
lastmod: ["lastmod", ":fileModTime", ":default"]
hideMeta: false
#
stackoverflow hugo doc discourse hugo hugo post dates in the hugo pages stackoverflow
Note: To enable adding “lastmod” property to every post set
(setq org-hugo-auto-set-lastmod t)