1025hugo Shortcuts

Quick run through hugo Installation & Update on macOS.

Install hugo

brew install hugo

Check Version

hugo version

hugo v0.109.0+extended darwin/amd64 BuildDate=unknown

Upgrade hugo

brew upgrade hugo
Warning: hugo 0.109.0 already installed

Create New Site

hugo new site my-new-hugo-site
cd my-new-hugo-site
git init
git submodule add https://github.com/theNewDynamic/gohugo-theme-ananke themes/ananke
echo "theme = 'ananke'" >> config.toml

hugo does not come with an in-built theme, therefore we need to clone the anake theme into themes/ananke. More hugo themes. Clone and update config.toml.

Serve Site

hugo server

Build Site

Just hugo, nothing else.

hugo
Start building sites … 
hugo v0.109.0+extended darwin/amd64 BuildDate=unknown
INFO 2022/12/26 19:37:15 syncing static files to /

                   | EN  
-------------------+-----
  Pages            | 10  
  Paginator pages  |  0  
  Non-page files   |  0  
  Static files     |  1  
  Processed images |  0  
  Aliases          |  1  
  Sitemaps         |  1  
  Cleaned          |  0  

Total in 154 ms