Sync USAGE.md.
This commit is contained in:
parent
08bb3f473e
commit
ec2a611cc9
31
USAGE.md
31
USAGE.md
|
@ -1,35 +1,44 @@
|
|||
# How to write ebooks with Markdown
|
||||
|
||||
* Organize articles in directories, each directory is a chapter.
|
||||
* Order of chapters is hard-coded in file `convert.sh`, so that we can avoid
|
||||
complex/unnecessary way to order them.
|
||||
* Chapter title is defined in file `_title.md` under chapter folder.
|
||||
* Chapter summary is defined in file `_summary.md` under chapter folder.
|
||||
* Addition links stored in file `_links.md` will be appended to chapter.
|
||||
|
||||
```
|
||||
- 1-introduction/
|
||||
|- _title.md
|
||||
- chapter_name_1/
|
||||
|- _title.md: Chapter title. REQUIRED
|
||||
|- _links.md: Addition links, will be appended to chapter. OPTIONAL
|
||||
|- _summary.md: Summary text of this chapter, will be displayed under
|
||||
chapter title. OPTIONAL
|
||||
|- what_is_iredmail.md
|
||||
|- why_choose_iredmail.md
|
||||
|- price.md
|
||||
- 2-faq/
|
||||
- 3-install/
|
||||
- chapter_name_2/
|
||||
- chapter_name_3/
|
||||
...
|
||||
- html/css/markdown.css
|
||||
- html/images/
|
||||
```
|
||||
|
||||
* Articles will be ordered automatically, if you want to force the order,
|
||||
prepend a digit number and `-` in article files. e.g.
|
||||
* Articles will be ordered automatically, if you want to specify the order,
|
||||
prepend a digit number and `-` in article files, script `convert.sh` will
|
||||
remove this prefix during converting Markdown source file to HTML file. e.g.
|
||||
|
||||
```
|
||||
- 1-introduction/
|
||||
- chapter_name_x/
|
||||
|- _title.md
|
||||
|- 1-what_is_iredmail.md
|
||||
|- 2-why_choose_iredmail.md
|
||||
|- 3-price.md
|
||||
```
|
||||
|
||||
* Convert all Markdown files to HTML static files. Script `convert.sh` will
|
||||
also generate index file `html/index.html` (which includes all articles with
|
||||
valid internal links).
|
||||
* Run script `convert.sh` to convert Markdown files to HTML static files.
|
||||
|
||||
* It will generate index file `html/index.html` which includes all articles
|
||||
with relative links to HTML files.
|
||||
* it also generates README.md file used by bitbucket.org as index page.
|
||||
|
||||
```bash
|
||||
$ bash convert.sh
|
||||
|
|
Loading…
Reference in New Issue