[hugo, static, website, generator, class, academic]


Install Hugo

Hugo comes in two versions: a standard one and a so-called “extended” one. Here, we need the extended version.

Before you start, please check that Git is properly installed and set up.

MacOS & Linux

Make sure you have Brew installed. Then, to install Hugo. Brew automatically installs the “extended” version:

brew install hugo

Windows

  1. Install the ZIP file of the latest hugo-extended release for Windows from this repository (scroll down to “assets”)
  2. Move the ZIP file and extract its content in the c:\Hugo\bin folder on your local machine. You should see three new files: Hugo executable (i.e., hugo.exe file), license.md, and readme.md.
  3. Add Hugo to your Windows PATH settings by following these steps. Click on System -> Advanced System Settings -> Environment Variables. In the User variables section, double-click on PATH and click New. Then, type the file path C:\Hugo\bin where the hugo.exe was extracted. Click on OK and exit.
  4. Verify if Hugo is installed properly. Type hugo help on a command prompt window. You should see the following output:

Verify Hugo Installation

If you use Chocolatey:

choco install hugo-extended -confirm

Alternatively, see other installing options here.

Create a New Local Website

You’re now ready to start.

To create a new Hugo website, move to a directory of your choice and run:

hugo new site yourwebsitename

Where yourwebsitename is the name of the folder you’ve just created. Your entire website will live inside this folder on your computer.

Congrats! In the next sections, you will start tweaking your new website.

Tip

Check out the Hugo documentation for the official quick start guide.

Contributed by Andrea Antonacci