Pages

Sunday, 22 January 2017

搭建基于haskell的静态博客程序cattheory-blog

先按此文http://briteming.blogspot.jp/2016/07/hakyll.html,安装stack,ghc,hakyll.

cd /usr/local
git clone https://github.com/cattheory/blog




cd _site
root@AR:/usr/local/cattheory.com/_site# ls
archive.html  atom.xml    css  images  index.html  pages    posts  tags
root@AR:/usr/local/cattheory.com/_site#
(可见/usr/local/cattheory.com/_site就是静态网站的根目录)

新建源帖:
root@AR:/usr/local/cattheory.com/_site# cd ../posts
root@AR:/usr/local/cattheory.com/posts# nano 2017-01-22-test-1.md
root@AR:/usr/local/cattheory.com/posts# cat 2017-01-22-test-1.md
---
title: 测试1
author: brite fisherman
tags: misc1, misc2, misc3
description: 点击标题看全文
mathjax: on
---

这是测试1.

看看如何?

root@AR:/usr/local/cattheory.com/posts# cd ..
root@AR:/usr/local/cattheory.com# ./site build

演示网站:http://cb.bright.biz.st
项目地址:https://github.com/cattheory/blog

No comments:

Post a Comment