Andrew Aitken


I was curious about having my blog deployed whenever I push a commit, so after a bit of googling I found this handy tutorial by Mathieu Leplatre.

There were a few differences, I am using the GitHub user pages, where he was using a project page, so my blog output needs to sit on the master branch and not gh-pages.

I'll just show what I had to do differently, so here is my .travis.yml file. I had a few issues with it, but nothing YAML lint and Travis WebLint couldn't sort out.

language: python
python: 2.7
    secure: "my-encrypted-token (truncated for size)"
    - source
  - "pip install -r requirements.txt"
  - "make publish github"

And my modified Makefile

github: publish
    cp .travis.yml output/
    ghp-import -b master $(OUTPUTDIR)
    @git push -fq https://${GH_TOKEN}$(TRAVIS_REPO_SLUG).git master > /dev/null

Key differences are the -b master parameter passed to ghp-import which tells it to update the master branch. I also copy my .travis.yml file to the output as it tells Travis only to build the source branch and I don't want it trying to rake my html.

You can see it all on my GitHub page.

Older Articles

Nearly there

Fri 05 July 2013 My Blog

Well, I've updated the site. Unfortunately all my posts are now marked as being created in the last few days. So that's on my "to fix" list.

In the mean time though, you can now browse my site on a phone.

Read more

Making things squishy

Mon 24 June 2013 My Blog

I've been playing about with Twitter's Bootstrap and decided to convert my blog over to use that.

I've got an offline version complete and will be updating the site shortly, it will also be responsive and look lovely on mobile devices.

Read more

Another small update

Wed 29 August 2012 My Blog blog

I think I've been to BadgerBadgerBadger more times than I've written blog posts. I keep thinking something I've done would be interesting to blog about but when it comes down to it I can never think of what to write.

For now though, I've just converted ...

Read more

Small update

Wed 18 January 2012 My Blog blog

Finally got round to fixing an issue where a 404 was being recorded as error. Should save some disk space :) I've also added a new friend link for Greg and Jen who are off traveling round the world.

Hopefully this will inspire me to get my ass in gear ...

Read more

Page 1 / 1