1 Star 0 Fork 0

Cweili / tini

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
README.md 1.50 KB
一键复制 编辑 原始数据 按行查看 历史
Cweili 提交于 2014-11-29 00:16 . update readme

Tini 急速静态博客

Tini 是一个使用 markdown 撰写日志,通过 Gulp 进行编译的静态博客,拥有极致的访问速度。

演示:Cweili Beta

安装

  1. 安装 Node.JS,
  2. 切换到 Tini 目录
  3. 全局安装 gulp npm install gulp -g
  4. 安装 node 依赖 npm install
  5. 首次请执行 gulp 初始化

操作

配置

可以通过修改配置文件 config.coffee,对博客进行定制。

写新文章

gulp new

新文章会建立在 posts 目录下,你可以重命名并编辑他。

发布

gulp publish

博客会被编译并索引到 public 目录下,你可以将这个目录的内容进行部署。

内置服务器

gulp server

启用一个服务器,使用 http://localhost/ 预览你的博客,并且编辑文章时可以实时看到效果。

主题包开发

目录结构

  • 主题包目录为 themes
  • 主题目录下的各个目录作用为:
    • assets 资源
    • scipts 脚本(支持CoffeeScript)
    • styles 样式(支持LESS)
    • views 视图模板(AngularJS)
  • views 目录下至少需要以下模板:
  • 需要一个入口页面 index.html,在此引入样式、脚本、压缩配置等
  • 文章模板 partial/post.html
  • 文章列表模板 partial/posts.html

编译

gulp theme

编译主题包

开发服务器

gulp theme-dev

监测主题包文件修改,及时编译生效。

CoffeeScript
1
https://gitee.com/Cweili/tini.git
git@gitee.com:Cweili/tini.git
Cweili
tini
tini
master

搜索帮助