Total Pageviews

Monday, 28 October 2013

在linux vps上搭建基于ruby的静态博客程序-nesta

gem install nesta
nesta new nesta-site
cd nesta-site
bundle install
gem install mr-sparkle
bundle exec mr-sparkle config.ru  (then point your web browser at http://localhost:8080)
(如果提示mr-sparkle is not part of the bundle,则编辑当前目录下的Gemfile文件:
as3:~/nesta-site# nano Gemfile
as3:~/nesta-site# cat Gemfile
source 'http://rubygems.org'

gem 'nesta', '0.9.13'
gem 'mr-sparkle' (加上此行)
as3:~/nesta-site# nohup mr-sparkle config.ru > /dev/null & (这样,即可预览一下网站http://as3.brite.biz:8080/)
as3:~/nesta-site# cd content/pages/
as3:~/nesta-site/content/pages# nano test1.mdown
格式如下:
Date: 29,October,2013
(这里必须隔开一行)
这是测试1.

as3:~/nesta-site/content/pages# cd ~/nesta-site
as3:~/nesta-site# nohup mr-sparkle config.ru > /dev/null & (这个就是更新静态网站的命令)

demo site: http://as3.brite.biz:8080/,这个程序真是很简陋,生成的帖子竟然没有单独的链接。
项目地址: https://github.com/gma/nesta