Ubuntu14.04+jekyll+github pages build a static blog

Source: Internet
Author: User

Official tutorial http://jekyllrb.com/docs/installation/1. Jekyll Introduction

    • Simple: No database, No comments, no need to update the version, just care about the content of the blog.
    • Static: A deployable static site can be built using only Markdown (or Textile), Liquid, HTML & CSS.
    • Blog form: Custom addresses, categories, pages, blog content, and custom layout designs are the top citizens in the system.
    • Jekyll Detailed Introduction
2. About Github pages
    • GitHub pages is provided to each user by GitHub to introduce and showcase their projects. We can use Jekyll to generate a static website, and then deploy it on GitHub pages, leveraging GitHub's servers to run our own web site.
    • Github pages Detailed information
3. Installation Environment 3.1 Install ruby Environment
    • Ruby was installed because Jekyll was developed in Ruby. The ruby environment is not installed by default on ubuntu14.04 Lts and needs to be installed on its own. The installation commands are as follows:
sudo apt-get install Ruby1.9.1-dev
Orsudo apt-get install ruby-dev
(Be sure to use this dev version, otherwise it will be wrong with the other version, detailed to see the most behind the exception and its resolution)
    • After the installation is complete, enter RUBY-V in the terminal and the following results indicate that the installation was successful:
Ruby 1.9.3p484 (2013-11-22 revision 43786) [X86_64-linux]

3.2 Install the NODEJS environment (seemingly not installed is also possible, GEM is the package manager of Ruby, we will install Jekyll through this manager)

If an error occurs, refer to the following

    • The reason to install Nodejs is that Ruby's gem management requires a NODEJS environment, and after completing the ruby environment, entering GEM-V in the terminal, the following results occur:

    • Error message Tip: You cannot find a JavaScript environment, just enter the following command in the terminal:
sudo apt-get install Nodejs
    • Nodejs after the installation is complete, re-enter GEM-V in the terminal, the following results indicate that the installation was successful:
1.8.23
3.3 Installing the Jekyll Environment
    • Enter the following command in the terminal to install the Jekyll, this process is relatively slow, and the source is related to:
sudo gem install Jekyll
(Run an exception 2, modify the following command: sudo gem install jekyll-v ' 2.0.0.alpha.1 '   )
    • After the installation is complete, enter the following command in the terminal to verify the success of the Jekyll installation:
    • If the directory is created successfully, the Jekyll installation is successful and can be done later.
      -jekyll Installation Details
3.4 Installing Git
    • Now that you're deploying your Web site on a GitHub page, Git is a natural use, and you can install git using the following command:
sudo apt-get install git
    • Enter Git–version in the terminal and the following results indicate that the GIT installation was successful:
    • Git installation Detailed steps
3.5 Create a new warehouse on GitHub
    • Create a new warehouse on GitHub, the name of the library: Username.github.io, which is used to store the content of the blog.
    • Detailed information
4. Reference
    • Install Git under Linux
    • GitHub pages Configuration
    • Jekyll Configuration
5. Exceptions and how to resolve them

Exception 1:

The ruby version on the exception 2:ubuntu is relatively low, which can be solved by restricting installation Jekyll

sudo gem install jekyll-v ' 2.0.0.alpha.1 '

Exception 3:

Ubuntu14.04+jekyll+github pages build a static blog

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.