Getting Started

Release Date: Update date: Total Words: 205 Reading time: 1m byIP: 上海 Copy Url

Quick start guide for Hugo and hugo-bootstrap-x theme, covering installation, site initialization, and running.

Install Hugo

It is recommended to install the Hugo Extended edition to fully support SCSS/SASS compilation and modern asset pipelines:

macOS (Homebrew)

bash
brew install hugo

Linux (Debian / Ubuntu)

bash
sudo apt-get update
sudo apt-get install -y hugo

Alternatively, download the latest .deb or prebuilt binary package from Hugo GitHub Releases.

Windows (Chocolatey / Scoop)

powershell
choco install hugo-extended
# or
scoop install hugo-extended

Verify your installation:

bash
hugo version

Create a New Site

Use the hugo new site command to create a new Hugo site skeleton:

bash
hugo new site myblog
cd myblog
git init

Install Theme

Add the hugo-bootstrap-x theme into the themes/ directory. Using Git Submodule is recommended for easier updates:

bash
# Option 1: Git Submodule (Recommended)
git submodule add https://github.com/xiexianbin/hugo-bootstrap-x.git themes/hugo-bootstrap-x

# Option 2: Direct clone
git clone https://github.com/xiexianbin/hugo-bootstrap-x.git themes/hugo-bootstrap-x

Next, add the theme to your site configuration file hugo.toml (or config.toml):

toml
theme = "hugo-bootstrap-x"

Start Local Server

Run Hugo’s built-in development server from your site root, with the -D flag to render draft posts:

bash
hugo server -D

Open http://localhost:1313/ in your browser to view your site live with automatic hot reloading (LiveReload).