Centos7安装Jekyll

安装ruby

教程链接

安装RubyGems

yum install gem

使用以下命令替换 gems 默认源

# 添加 TUNA 源并移除默认源
gem sources --add https://mirrors.tuna.tsinghua.edu.cn/rubygems/ --remove https://rubygems.org/
# 列出已有源
gem sources -l
# 应该只有 TUNA 一个

安装Jekyll

gem install jekyll bundler

创建运行一个服务

# Create a new Jekyll site at ./myblog
jekyll new myblog

# Change into your new directory
cd myblog

# Build the site on the preview server
bundle exec jekyll serve

# Now browse to http://localhost:4000

引用官网

猜你喜欢

转载自my.oschina.net/u/3656540/blog/1794281