a hugo theme for redbrick users

Cian Butler 8312b42404 Merge branch 'master' of github.com:redbrick/redbrick-hugo 3 months ago
archetypes 1cf36e530f add theme.toml 6 months ago
exampleSite 0d8d0f9a99 update readme 6 months ago
layouts e856c74fe9 add initial theme elements 6 months ago
static 0d8d0f9a99 update readme 6 months ago
.gitignore 0964393455 Initial commit 6 months ago
LICENSE 0964393455 Initial commit 6 months ago
README.md 0094b7590f Fixed syntax errors 6 months ago
theme.toml 1cf36e530f add theme.toml 6 months ago

README.md

Redbrick-hugo

A theme for hugo

Installation

$ cd themes
$ git clone git@github.com:redbrick/redbrick-hugo.git
$ cp -r redbrick-hugo/exampleSite/* ..

Creating your first site

To generate your first site you can type the command:

$ hugo new site ~/my-website

Jump into your new site and have a look around at the files

$ cd ~/my-website
$ ls -F

Install your theme

$ git clone git@github.com:redbrick/redbrick-hugo.git themes/redbrick-hugo
$ cp -r themes/redbrick-hugo/exampleSite/* .

Open up the config.yaml file to change the configuration of your website

$ nano config.yaml

Making it your own

Changing images

To get started you will want to add your own picutres for your avatar, banner and about photos. To change these you will need to add these to your /static/img/ folder.

  • avatar.jpg
  • banner.jpg
  • about.jpg

Customising pages

  • Change the baseURL baseURL: "http://www.redbrick.dcu.ie/~username/" to inclue your username
  • Change title: A Redbrick users site to the title of your main page
  • You can also add your social media links in here after link: '#'

Adding new pages

$ hugo new about.md
  • This will generate a new page with some metadata all ready in it

Take a look at this new file with

$ cd content
$ nano about.md

Building the Site

To build your site we type the command

$ hugo

This will output all the code into the public folder.

Note: Hugo can be weird if you don't delete your public before you generate everytime

Warning: rm -rf is sometimes dangerous. Don't run in sudo unless you know what you are doing

$ rm -rf public

This will perminantly delete the public folder

You can also achieve the same thing by

$ hugo --cleanDestinationDir

Looking at the site locally

If you wanna look at your site before you go and deplot it (recomended)

$ hugo server

This will generate a site on localhost:1313