github jekyll markdown

1. github can generate a personal site automatically: create a new repository and turn to setting page below which there is a botton 'generate github pages'.

2. automatic generated pages have the style files which can be used in our own site.

3. build my own site via jekyll : http://blog.csdn.net/on_1y/article/details/19259435. Note that if you are using your personal site, in other words project name is 'yourname.github.io', master branch is recoginzed by github otherwise you need to init your site in gh-pages branch.

4. learn to use markdown: https://www.zybuluo.com/mdeditor?url=http://www.zybuluo.com/static/editor/md-help.markdown

5. if you want to use latex math equation, includes following in head in your layout file.

 11     <!-- MathJax Section Start -->
 12 
 13     <script type="text/javascript"
 14     src="http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML">
 15     </script>
 16     <script>
 17         MathJax.Hub.Config({
 18               tex2jax: {
 19               skipTags: ['script', 'noscript', 'style', 'textarea', 'pre']
 20               }
 21         });
 22         MathJax.Hub.Queue(function() {
 23             var all = MathJax.Hub.getAllJax(), i;
 24             for(i=0; i < all.length; i += 1) {
 25                 all[i].SourceElement().parentNode.className += ' has-jax';
 26             }
 27         });
 28     </script>
 29 
 30     <!-- MathJax Section End -->

6. if you use redcarpet as your markdown explainer, '_' need to be convert into '\_', which is not very convenient for me. Kramdown is the origin explainer used by github which support original latex equation format and github code highlight style. But pygments is not compatible with kramdown in jekyll ( I have tried to turn on the pygments in jekyll, but code still remains clean), kramdown use 'coderay' as its highlighter. If you want to use this feature, you need to have coderay library installed. In addition, the kramdown used by github does not support coderay, you need to generate you own static pages at first and then upload.

转载于:https://www.cnblogs.com/wead-hsu/articles/3937108.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值