Demo site for Start Bootstrap Clean Blog ported to a Hugo theme.
This demo site has been setup with the following commands.
hugo new site sbcb-demo
cd sbcb-demo
git init
git remote add origin [email protected]:humboldtux/sbcb-demo.git
git add .
git commit -m "Initial commit"
git push --set-upstream origin master
git push
git checkout --orphan gh-pages
git rm --cached $(git ls-files)
rm -f *
touch index.html
git add index.html
git commit -m "Initial commit on gh-pages branch"
git push origin gh-pages
git checkout master
git clone https://github.com/humboldtux/startbootstrap-clean-blog.git themes/startbootstrap-clean-blog
nano .gitignore
Have a look at the config.toml in this repository as a starting point.
hugo new about.md
hugo new contact.md
You need to set the type to about for about.md, and contact for contact.md. You can change the title too. Have a look at the files content/about.md and content/contact.md for a starting point.
The contact page uses formspree.io to send emails without requiring a backend scripting langage.
For formspree.io to work, you need to change [email protected] in themes/startbootstrap-clean-blog/static/js/clean-blog.js, line 29, with your email, as i don't know yet how to update a static file with a Hugo configuration variable.
For you to avoid editing directly the theme file, a nicer way to do it is to copy this file in your site static/js directory, and then edit it:
mkdir static/js
sed -i s/[email protected]/[email protected]/g static/js/clean-blog.js
for i in {01..10};do hugo new post/post-${i}.md;done
hugo server --watch --verbose -D -F
If it's ok, remove draft = "true" from content/post/ files.
rm -rf public
git add .
git commit -m'Add base content'
git subtree add --prefix=public [email protected]:humboldtux/sbcb-demo.git gh-pages --squash
git subtree pull --prefix=public [email protected]:humboldtux/sbcb-demo.git gh-pages --squash
hugo
git add -A
git commit -m "Updating site"
git push origin master
git subtree push --prefix=public [email protected]:humboldtux/sbcb-demo.git gh-pages --squash