Step 1: create a github pages repo
In my case, I made a new repo called tleyden/tleyden.github.io.
Step 2: push an index.html
Clone the repo
Add some content
Commit and push
1 2 3
Step 3: see if it actually worked
Go to http://tleyden.github.io/ to see if it works.
It did not work. WTH!?
Oh wait, it says: It may take up to ten minutes until your page is available.
Patiently hit reload 5 times / minute, and 7 minutes later .. IT WORKS!
Step 4: get rvm (octopress dependency)
1 2 3
Step 5: get ruby 1.9.3 (octopress dependency)
1 2 3 4 5 6 7 8 9 10
Let’s try this again ..
45 minutes later, it finally worked.
Step 6: get octopress
Follow the Setup Ocotpress instructions
Step 7: recreate repo
So this is a little awkward, and looking back I wish I hadn’t pushed that index.html earlier, because it interferes with the github push in the next step.
- Delete your entire github repository:
- Create a new empty github repository:
Step 8: deploy to github pages
Follow the Deploy to Github pages instructions.
There is one step that is crucial if you don’t want to accidentally lose your blog content:
1 2 3
After doing that, your github repo should have two branches:
- Master: the “published blog” goes here, and will have a top-level index.html
- Source: the entire octopress source tree, plus a “source” and “sass” directory. The “source” directory is where your blog markdown content will actually live.
Step 9: write a blog entry
Follow the New blog post instructions.
Step 10: re-deploy
From the last step in the Deploy to Github pages instructions, do the following:
Step 11: revel in it’s beauty
Step 12: Oops, don’t forget to push the source changes!
Even though the blog content is deployed (eg, your master branch with your content has been pushed to github), the source is still sitting on your computer. If your hard drive crashes, you’ll lose your markdown, which is no fun.
Here’s how to push the latest changes of your source files up to github:
1 2 3