chrismjohnston / ChrisJohnstondotDev_blog

A blog that I created to play with Hugo

Home Page:https://chrisjohnston.dev

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Netlify Status

ChrisJohnstondotDev_blog Build Instruction

Step 1

hugo new site classic

Step 2

echo "# my-new-hugo-blog" >> README.md

Step 3

git init

Step 4

git add README.md

Step 5

git commit -m "first commit"

Step 6

git branch -M main

Step 7

git remote add origin https://github.com/<Your-GitHub-username>/ChrisJohnstondotDev_blog.git

Step 8

git push -u origin main

Step 9

cd themes/
// make this directory if it doesnt exist

Step 10

git submodule add https://github.com/goodroot/hugo-classic.git

This is necessary to deploy to Netlify. Also it seems that submodules are required if you want to keep your theme updated. I just discovered submodules three days ago so I'm learning as I go.

Step 11

cp -a hugo-classic/exampleSite/. ../

This command must be executed from the themes folder. It copies and archives (the -a flag) the hugo-classic/exampleSite/. directory and its contents and put the contents in the folder one level above, the main classic/ folder.

Step 12

cd .. && hugo server

SUCCESS!!! You should have a working hugo server on your local machine and be able to see the site at the localhost address output in the terminal after this command.

About

A blog that I created to play with Hugo

https://chrisjohnston.dev


Languages

Language:HTML 86.9%Language:CSS 13.1%