Create a blog via Jekyll and post to Github
Table of Contents
Jekyll is a static website generation framework written in Ruby language. The following is the official website introduction.
Jekyll is a static site generator. You give it text written in your favorite markup language and it uses layouts to create a static website. You can tweak how you want the site URLs to look, what data gets displayed on the site, and more. –Jekyll1
When installing Jekyll, you first need a Ruby package management
environment. The commonly used package manager of the Ruby programming
gem. For example, executing the following statement in
Ubuntu will also install
apt install ruby-dev
gem, make sure its execution path is in our
environment variable. If you do not use the above method, but use
virtual environment management tools such as
rbenv, just call the
gem configured in the virtual environment. Then you can install Jekyll
by executing the following statement.
gem install jekyll
Publish blog to Github
After installing Jekyll, you must hope to post something to Github first to see the effect. Especially understand this mood.
Then next, before blogging, let's firstly use Jekyll installed to generate a default site and publish it to Github. Execute the following command in the current path where you want to manage the blog locally.
jekyll new folder-name-for-your-blog
Then a folder called
folder-name-for-your-blog will be generated under
the current path, which is the new blog source code created by Jekyll.
Then create a repository called
Github. After creating the repository, Github will prompt how to use
push local content to the repository. Follow the wizard to
push the contents of the
folder-name-for-your-blog folder you just
created to this repository.
Then wait a few minutes to open
through your browser, and you can see Jekyll's welcome page if nothing
This site is also created by the above method.
(Postscript on June 14, 2020)
Welcome to contact and leave a message.