Simple construction of Jekyll

Source: Internet
Author: User
Tags ssh
 
   First, go to the Github.io URL, go inside and build ruby and Gem in the tutorial. When you enter Ruby and Gem in cmd, the following occurs: 
 
$ ruby
asus@desktop-5j15lt4 MINGW32 ~/desktop/mylog (gh-pages)
$ gem
RubyGems is a sophisticated package Manager for Ruby.  This was a
basic help message containing pointers to more information.
  Usage:
    gem-h/--help
    gem-v/--version
    gem command [arguments ...] [Options ...]

  Examples:
    gem install rake
    gem list--local
    gem build package.gemspec
    gem Help install

  Further help:
    Gems help commands            list all ' gem ' commands
    Gems help Examples            show some examples of usage< C19/>gem help gem_dependencies    Gems Dependencies File Guide
    Gems help platforms           Gems platforms
    Guide Gem Help <COMMAND>           Show Help on COMMAND
                                   (e.g. "Gem help Install")
    Gem Server                   present a Web page At
                                 http://localhost:8808/with
                                 info about installed Gems

This means that your installation was successful.
and then. Install the image, create a new folder locally, and use cmd to install the stuff.
$ gem sources-a http://gems.ruby-china.org/
Install Jekyll 3.0 version of the
 $ gem install jekyll-v ' 3.0 '
 also has this also to install the
$ gem install minima
$ gem Install bundle
installed successfully to After that will appear in the file
$ ls
_config.yml  _posts/  _site/  about.md  css/  feed.xml gemfile  Gemfile.lock  index.html
However, when we accidentally delete the contents of the inside, you can also generate Jekyll
$ jekyll New blog
The back of which blog is your own folder
into this folder
$ cd Blog
$ jekyll serve
can be run locally. Open
The localhost:4000 page and it appears.
but. We also want to push on GitHub, what's the half of it?
First: Git init
is to create a repository locally
git remote add Origin git@github.com:/yiiyang/yiiyang.github.io
This is associated with the remote repository, which is necessary for the action
$ git add *
-F $ git commit-m ' 1 '
$ Git push Origin master
then we will find this push not up, what should I do?
since our first push, GitHub has SSH encryption protocol, so
$ git config--global user.email "own Mailbox"
$ ssh-keygen-t rsa-c  " Own Mailbox "
$ ssh-keygen-t rsa-c" own mailbox "
vim/c/users/asus/.ssh/id_rsa.pub into the
inside and copy the stuff inside to your GitHub
$ Git push origin master
Let's go up and push
.
if we want to run locally, we have to go
into our own file and run
$ jekyll build
$ jekyll serve--watch
off. Just very good ...


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.