The shortest intro of GitHub Pages
GitHub Pages: Static website (blog) hosting service
Jekyll: Static website generator, written in Ruby. Converts markdown files into html files.
To begin:
- Install Ruby and Jekyll
- Download a Jekyll theme you like (a blog template)
- Install the rest files using bundle command
- Test your website locally
- type “bundle exec jekyll serve” in the package directory
- type “localhost:4000/” at your browser
- Create a git repo (“username.github.io”) at GitHub website
- git push your code to remote repo
- Check out “https://username.github.io”
Posting process:
- Create _posts directory at your package directory if you don’t have it yet.
- Go to _posts directory and write a post as a markdown file
- Test your code and see website preview from your local computer
- git push your final file(s) to your remote git repo
- Then GitHub pages automatically runs Jekyll to update your website
Note: _config.yml file is read only once at build (bundle command at your local computer)
Leave a comment