Elisabeth Henry
54ca041d5a
Clean Book constructors API
...
- Book::new takes an additional `options` parameter.
- Book::new_from_file_with_options becomes `new_from_file`, which got
deleted.
This way, each constructor takes an `options` parameter (which can
be set to `&[]` for default options), allowing derived constructors to
not replicate the setting options code.
2016-03-03 20:56:28 +01:00
Elisabeth Henry
0a39bee213
Make Book parse inline yaml blocks, not just ignoring them.
2016-03-01 16:00:43 +01:00
Elisabeth Henry
8b8d847a7d
Consider it is a YAML block only if first line is at the beginning of a
...
doc or preceded by an empty line, to avoid the case where
Foo
---
Bar
---
gets counted as a YAML block. The only ambiguous case left is if you had wanted to make two rules,
but can easily be avoided by using either *** for rules, or by using more dashes.
2016-03-01 04:02:49 +01:00
Elisabeth Henry
fa5393641b
Crowbook now ignores YAMLÂ blocks (i.e., delimited by two lines containing ---, must contain valid YAML) in Markdown files
2016-03-01 01:28:36 +01:00
Elisabeth Henry
dae4b02a00
tests/book.rs: updated so it works again with changed api
2016-02-29 01:12:29 +01:00
Elisabeth Henry
bd8cc636ca
tests/book.rs: removed unecessary use
2016-02-27 04:42:20 +01:00
Elisabeth Henry
67320cd5cf
updated tests/book.rs to new path for config.book
2016-02-26 23:30:39 +01:00
Elisabeth Henry
8175812f36
added zip.command to book options
2016-02-26 18:51:13 +01:00
Elisabeth Henry
722e80ec35
tests/book.rs: call render_epub instead of render_all so it doesn't fail if latex is not present
2016-02-26 17:41:51 +01:00
Elisabeth Henry
bd2971ab61
no longer change current directory, as it generated problems in multithreaded envs
2016-02-26 17:33:33 +01:00
Elisabeth Henry
431907cf39
removed tests/test_helper.rs as with tests being moved to library it was not very useful (TODO: add integration tests
2016-02-26 15:36:15 +01:00
Elisabeth Henry
d21dbc529e
module cleaner is now private
2016-02-26 00:02:09 +01:00
Elisabeth Henry
2991099ecd
modules token and parser are now private
2016-02-25 23:59:33 +01:00
Elisabeth Henry
d513a03703
moved tests/toc.rs inside src/lib so module toc can be private
2016-02-25 23:33:54 +01:00
Elisabeth Henry
32e7231fba
added a dash escape test in test.md
2016-02-25 19:56:30 +01:00
Elisabeth Henry
ab47a0d3bb
updated tests to they pass
2016-02-24 20:58:51 +01:00
Elisabeth Henry
8d763992ff
fixed bug in toc.rs
2016-02-24 19:48:55 +01:00
Elisabeth Henry
0a19bb7929
added a toc module
2016-02-24 19:13:59 +01:00
Elisabeth Henry
55e9458256
tests/html.rs: fixed to new interface
2016-02-24 15:05:46 +01:00
Elisabeth Henry
d081767a83
added a test md file (and book) in tests directory
2016-02-23 22:41:22 +01:00
Elisabeth Henry
ae98dd6661
added a test_helper::test_eq function for tests, in order to make errors more readable
2016-02-23 14:23:56 +01:00
Elisabeth Henry
b537edfa62
fixed tests/html.rs
2016-02-22 23:52:46 +01:00
Elisabeth Henry
aae17e9a09
added tests for parser for footnotes and tables
2016-02-22 19:03:58 +01:00
Elisabeth Henry
25920495ab
tests now compile again
2016-02-19 16:27:41 +01:00
Elisabeth Henry
61a6354398
html renderer no longer moves its vector
2016-02-18 22:58:34 +01:00
Elisabeth Henry
10f58f9002
html renderer is starting to work \o/
2016-02-18 22:05:54 +01:00
Elisabeth Henry
583623c23e
moved from Cow to string because too painful sorry
2016-02-18 19:21:55 +01:00
Elisabeth Henry
940b5c99fa
initial commit
2016-02-18 04:06:14 +01:00