Blog engine writen on Perl and Mojolicious. This blog engine rewriten from Twist.
- filesystem-based storage
- tags
- RSS (articles, tags)
- static pages
- drafts
- archive
- POD and Markdown
- Google Analytics and Yandex.Metrika
- Disqus comments
$ git clone http://github.com/sattellite/mojo-twist.git
$ cd mojo-twist
$ cp mojo-twist.json.example mojo-twist.json
$ cpan App::cpanminus && cpanm --installdeps .
$ morbo script/mojo_twist
Server available at http://*:3000.
Copy mojo-twist.json.example
to mojo-twist.json
and change it to fit your needs.
For configuration nginx web-server visit wiki.
Articles by default go into articles/
directory.
Article consists of file information and content with meta data.
20140317-article.pod
or
20140317T14:02:00-article.md
Where timestamp tells us when the article was created. Modified time is retrieved automatically from mtime
. Filename is the article's permalink url. Extention is article's format.
Title: My first article
Tags: blog, internet
Welcome!
[cut] Read more
This is my first article. It is in `md` format. And I can use all kind of
**tags**.
Every article should have metadata. Metadata ends with an empty line. If there is a [cut]
tag, article will be splitted into preview
and content
parts. preview
is shown when:
- article list is requested,
- rss.
For images used jQuery.LazyLoad. Preprocessor replace each <img src="..."
with <img data-original="..."
.
Design of blog is responsive and have good view in desktop and mobile browsers.
In configuration file you can specify your unique keys for Google Analytics or/and Yandex.Metrika. All needed scripts will be included in templates if theirs keys was setted.
If you have disqus
account then you can include disqus comments for each article by specifying your disqus shortname
.
Drafts are available under /drafts
url. Drafts in the articles/drafts
directory. Only you know the title, so it is safe to put there your drafts and refresh browser to see how it looks.
For example: file articles/drafts/2014-08-31-Sample-draft.md
will be available under drafts/Sample-draft
url.
Just put a pod
or md
into pages/
directory. Pages are available under /pages
url.