Skip to content

Hugo theme based on Bootstrap 5 and utilizing the NC State branding and resources.

Notifications You must be signed in to change notification settings

wspr-ncsu/hugo-theme-ncsu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

76 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

hugo-theme-ncsu

(Unofficial) Hugo (static site generator written in Go) theme using Bootstrap 5 and inspired by the NC State branding and resources.

Documentation:

Examples:

Older versions using the bs3 template (see releases):

exampleSite

This theme includes its own documentation in /exampleSite. With hugo installed, run a test server with:

$ cd exampleSite
$ hugo --themesDir ../.. server

Documentation is accessible at http://127.0.0.1:1313

Creating Website

  1. Install Hugo, this theme requires the "extended version" (or installed Dart Sass) because it uses SCSS.
  2. Follow the Hugo quickstart:
    1. Test if Hugo is correctly installed.
    $ hugo version
    1. Create new Hugo website structure
    $ hugo new site [project name]
  3. Add this theme as submodule in the themes folder:
$ cd [project name]/themes 
$ git submodule add [this repo url]
  • (Optional) Freeze submodule to specific release (tag):
$ cd [project name]/themes/hugo-theme-ncsu
$ git checkout v2024.08rc
  1. Copy example config file to website (from the theme's folder):
$ cp [project name]/themes/hugo-theme-ncsu/hugo.toml [project name]
  1. Edit hugo.toml config file to set website titles etc. (see documentation for settings).
$ nvim [project name]/hugo.toml

Deploying Website

Two ways:

  1. Using GitHub / Gitlab /... actions to deploy directly to web server.
    • GitHub pages supports Hugo
    • Alternative (free for static websites) services: Netlify, Vercel, Cloudflare
  2. Use hugo (just the CLI command hugo in the project folder) to generate a public folder with all the necessary HTML and resources to directly deploy to a web server
    • Might require to set baseURL variable in hugo.toml to web servers base url for resources to be loaded correctly.

Releases

  • The main branch receives continous updates and features (although likely at a slow and non-breaking rate because static website theme).
  • Frozen releases are tagged and released with the name of upcoming semesters, e.g., 2024.08 for Fall semester 2024, you can set specific releases in the submodule to freeze the theme version.

About

Hugo theme based on Bootstrap 5 and utilizing the NC State branding and resources.

Resources

Stars

Watchers

Forks

Packages

No packages published