# ArtiMark ArtiMark is a simple text markup language. It is designed to create XHTML files for EPUB books. Its default mode is for Japanese text. **CAUTION This is very early alpha version, so it's not stable at all, even the markup syntax** In the next release, the library name will change from ArtiMark to NoraMark. In NoraMark, the syntax will be more stable. ## Installation Add this line to your application's Gemfile: gem 'arti_mark' And then execute: $ bundle Or install it yourself as: $ gem install arti_mark ## Usage require 'arti_mark' document = ArtiMark::Document.parse(string_or_io) put document.html[0] # outputs 1st page of converted XHTML file An example of markup text (text is in english, but the paragraph style is japanese) # line begins with # is a comment. # you don't need to indent artimark text. lang: ja title: test title stylesheets: css/normalize.css, css/main.css art { h1: header 1 article comes here. linebreak will produce paragraph. blank line will procude div.pgroup. d.column { This block will produce div.column. Inline commands like [link(http://github.com/skoji/arti_mark/){this}] and [s.strong{this}] is available. } } The converted XHTML file test title

header 1

article comes here.

linebreak will produce paragraph.

blank line will produce

This block will produce div.column.

Inline commands like this and this is available.

Another example of markup text in non-japanese (paragraph style is default) # line begins with # is a comment. # you don't need to indent artimark text. lang: en title: test title stylesheets: css/normalize.css, css/main.css art { h1: header 1 article comes here. linebreak will produce br. blank line will procude paragraph. d.column { This block will produce div.column. Inline commands like [link(http://github.com/skoji/arti_mark/){this}] and [s.strong{this}] is available. } } The converted XHTML file test title

header 1

article comes here.
linebreak will produce paragraph.

blank line will produce paragraph

This block will produce div.column.
Inline commands like this and this is available.

Another example of markup text # Markdown-ish heading will creates section lang: ja title: test title stylesheets: css/normalize.css, css/main.css =: this is the first heading This line is in a section. This line is in a section. ==: this is the second heading This section is nested. =: this is the third heading will terminate lower level section The converted XHTML file test title

this is the first heading

This line is in a section.

This line is in a section.

this is the second heading

This section is nested.

this is the third heading

will terminate lower level section

In a near future version, you will be able to add custom commands. ## Contributing 1. Fork it 2. Create your feature branch (`git checkout -b my-new-feature`) 3. Commit your changes (`git commit -am 'Added some feature'`) 4. Push to the branch (`git push origin my-new-feature`) 5. Create new Pull Request