##kamelzcs's library##
###Prerequisites###
-
Ruby (only tested with 2.4)及相关组件(gem 2.4)
gem install nokogiri growl sass jekyll front-compiler maruku rouge jekyll-paginate
sudo update-alternatives --config ruby (switch default lib)
###Install###
-
git clone https://github.com/kamelzcs/kamelzcs.github.com.git kamelzcs
kamelzcs 为blog根目录,可随意更改名称
-
cd kamelzcs
-
mkdir _cache
_cache //如果你有自己的开源项目,参考_config.yml里的写法,会自动将项目的README.md download放置其中,最终build出一个适合本站主题的README页面
-
git clone https://github.com/kamelzcs/kamelzcs.github.com.git _compiled
_compiled //当jekyll生成html到_site后,同步到该目录,再推送至github下的个人blog,名字对应于Rakefile中的命名
-
git checkout --track origin/source
source //分支,专门用来编辑blog的html等
考虑到github不支持自定义插件 jekyll safe是开启状态,只能本地先合成html,再推送至github
基本想法:git clone两次,在source分支中编辑blog的相关的内容,在_compile里checkout至master,将由source分支中jekll合成的html同步到_compile,最后git commit到github服务端的master下。
###Rakefile###
-
rake build
用jekyll合成站点页面 -
rake ssend
pushes the compiled version to github. -
rake send
pushes the compiled version to github, after deleted the cache. -
rake kill
本地jekyll调试后,kill掉状态为T的jekyll和rake进程。 -
rake localtest
本地jekyll调试用。 -
rake new article-title
自动生成一个模板编辑页面,并用Mou打开
ps:
-
source分支的更新,直接在source分支下 rake commitSource
-
master的更新,在source分支下rake ssend
###Licence###
Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License
copy right @ kamelzcs | 主题由Bilal Syed Hussain提供,由kamelzcs修改