Open kakawait opened 7 years ago
Yes can be a great alternative to Travis. I will read that. Even more I heard smashing magazine is using Netlify
The .travis.yml
is actually quite terse:
script:
# Cleans out any possible old public directories -- just to be sure
- rm -rf public || exit 0
# Builds the site into the public dir
- ./binaries/hugo -s site/ -d ../public
deploy:
provider: pages
skip_cleanup: true
local_dir: public
github_token: $GITHUB_TOKEN # Set in travis-ci.org dashboard
on:
branch: master
Caveat: I committed the hugo binary to my repo (bad form, I know) so that I wouldn't have build steps for downloading it every time.
I followed this brief tutorial and cleaned up the above from there.
Could we maybe generalize this issue? Like "Add Continous Integration (CI)".
This project really needs it.
Nowadays, it may even be useful/possible to use GitHub actions for that.
Yes I think I'll move on GitHub actions rather than Travis
I now use Netlify - its free for Open Source projects like tranquil peak and its amazingly simple. A lot more simple than the travis approach. Take a read of https://www.netlify.com/blog/2015/07/30/hosting-hugo-on-netlifyinsanely-fast-deploys/
to deploy the example site I guess the deploy command would be:
mv exampleSite/* ./ && hugo_0.19
done!
(NB: Im not sure the path that it uses - that first part may have to change. NB2: You have to use hugo 0.19 - its default is 0.17 from memory and that crashes on tranquilpeak (due to this: https://github.com/kakawait/hugo-tranquilpeak-theme/issues/123)).