InkPaper is an static blog generator developed by Golang, No dependencies, Cross platform, Easy use, Fast build, Elegant theme.
InkPaper - An Elegant Static Blog Generator
-
Download & Extract Ink,Run
ink previewTips:Linux/macOS, use
./ink preview -
Open
http://localhost:8000in browser to preview
Edit config.yml, use format:
site: title: Website Title subtitle: Website Subtitle limit: Max Article Count Per Page theme: Website Theme Directory comment: Comment Plugin Variable (Default is disqus username) root: Website Root Path #Optional lang: Website Language #Support en, zh, ru, ja, Configurable in theme/lang.yml url: Website URL #For RSS Generating link: Article Link Scheme #Default Is {title}.html,Support {year},{month},{day},{title} Variables authors: AuthorID: name: Author Name intro: Author Motto avatar: Author Avatar Path build: output: Build Output Directory #Optional, Default is "public" port: Preview Port copy: - Copied Files When Build publish: | Excuted command when use 'ink publish'
Create any .md file in source directory (Support subdirectory), use format:
title: Article Title date: Year-Month-Day Hour:Minute:Second #Created Time,Support TimeZone, such as " +0800" update: Year-Month-Day Hour:Minute:Second #Updated Time,Optional,Support TimeZone, such as " +0800" author: AuthorID cover: Article Cover Path #Optional draft: false #If Draft,Optional top: false #Place article to top, Optional preview: Article Preview,Also use <!--more--> to split in body #Optional tags: #Optional - Tag1 - Tag2 type: post #Specify type is post or page, Optional hide: false #Hide article,can be accessed via URL, Optional --- Markdown Format's Body
- Run
ink publishin blog directory to automatically build and publish - Or run
ink buildto manually deploy generatedpublicdirectory
Tips: When
sourcedirectory changed,ink previewwill automatically rebuild blog,refresh browser to update
Default theme placed in theme folder, run npm install and webpack to rebuild in this folder.
page page.html (article list) and article.html (article), use variable with Golang Template syntax.
Created any .html file will be copied to source directory, could use all variables on site field in config.yml.
Support simple Jeklly/Hexo post convert, use:
ink convert /path/_posts
Local Build
- Install Golang environment
- Run
go get github.com/InkProject/ink, compile and get ink - Run
ink preview $GOPATH/src/github.com/InkProject/ink/template, preview blog
Docker Build (Example)
- Clone code
git clone git@github.com:InkProject/ink.git - Build image
docker build -t ink .in source directory - Run container
docker run -p 8888:80 ink
CC Attribution-NonCommercial License 4.0
https://github.com/InkProject/ink/issues
- [2017年02月25日] Fix bugs and merge some PRs
- [2016年07月11日] Fix bugs and merge many PRs
- [2015年08月15日] Bug fix, support RSS feed, improve theme
- [2015年07月04日] Bug fix, improve theme, support top, i18n, subtemplate
- [2015年06月04日] Build more platform, add archive and tag page
- [2015年03月01日] Release first beta version
- Improve Theme
- InkPaper Editor