Converts books written in Markdown to HTML, LaTeX/PDF and EPUB
LGPL-2.1 License
Bot releases are hidden (Show)
Published by lise-henry about 8 years ago
This release mainly introduces generation of proofreading copies,
allowing, if they are set (and crowbook
was compiled with the
proofread
feature) to generate proofreading copies, using tools to
check grammar and detect repetitions. These features are currently
experimental.
html.escape_nb_spaces
, if set to true (by default), will replaceoutput.proofread.html
,output.proofread.html_dir
and output.proofread.pdf
.proofread.repetitions
andproofread.nb_spaces
have been added.
proofread.nb_spaces
, if set to true, highlights non-breaking spaces so it ishtml.escape_nb_spaces
be set to true (default) toproofread.reppetitions
, if set to true, usesproofread.repetitions.fuzzy
,proofread.repetitions.max_distance
,proofread.repetitions.threshold
,proofread.repetitions.fuzzy.threshold
,proofread.repetitions.ignore_proper
. Note that this featurecargo build --release --features "repetitions"
.tex.command
is now xelatex
by default.clap
dependency is now optional, people who want to use Crowbookcrowbook = { version = "0.9", default-features = false }
. (clap
is still required to build aPublished by lise-henry about 8 years ago
The main objective of this release is to clean public interfaces, in
order to limit breaking changes in the future. Ideally, all pre-1.0
releases should thus be 0.9.x. Concretely, this meant three things:
tex.short
option, replacedtex.class
(default beingbook
). html.crowbook_link
has also been removed.temp_dir
-> crowbook.temp_dir
zip.command
-> crowbook.zip.command
verbose
-> crowbook.verbose
html.print_css
-> html.css.print
html.display_chapter
-> html_single.one_chapter
html.script
-> html_single.js
numbering
-> rendering.num_depth
numbering_template
-> rendering.chapter_template
display_toc
-> rendering.inline_toc
toc_name
-> rendering.inline_toc.name
enable_yaml_blocks
-> input.yaml_blocks
use_initials
-> rendering.initials
autoclean
-> input.autoclean
html_dir.css
-> html.css
(not really renamed, html_dir.css
license
, version
and date
. These metadata are{{{metadata}}}
allows to access the content. If theyhas_metadata
is also set to true, allowing to do{{{title}}} {{#has_version}}version {{{version}}} {{/has_version}}
.metadata.
. They will then be accessible in themetadata.foo: bar
you can access it in your templates with{{{metadata_foo}}}
.output.base_path
specifies a directory where the output files (setoutput.FORMAT
will be written.resources.base_path.templates
specifies where templates can berendering.inline_toc.name
can use {{{loc_toc}}}
to specify ahtml.top
and hstml.footer
are now considered as templates, so{{{metadata}}}
in it.html_single.one_chapter
is true.tex.class
is set to article
, chapters will be displayed as\sections
since article
class doesn't handle chapters.tex.class
is set to book
, margins are nowversion
and date
.import_config
only import options from another book file thatauthor: foo
then import_config: bar.book
won't erase the author previously set.import_config
now correctly translates the imported book'scrowbook --list-options
uses colours. This might hurt your eyes.Logger
to allows displaying messagesPublished by lise-henry about 8 years ago
This release adds support for syntax higlighting in code blocks,
customized top and footer blocks for HTML rendering, and the special
import_config
option that allows to import options from another book
file. It also provides (hopefully) better error messages.
import_config
is not really an option, but allows to importuse_initials
(set to false by default) makes Crowbook usehtml.highlight_code
(set to true by default) allows syntaxhtml.higlight.css
and html.highlight.js
can be used to providehtml.footer
allows to specify custom footer. If not set,html.crowbook_link
allows to disable "Generated by Crowbook"html.top
allows to specify a custom header that will beside_notes
has been renamed html.side_notes
.--verbose
.\chapter*{}
and <h1>
in LaTeXhtml.display_chapter
was set to true, meaning itImage
and StandaloneImage
were reversed inStandaloneImage
urls were not adjusted (meanning that runningcrowbook
from another directory failed).crowbook
is called from another directory (same fixError
type, and make more methods returnResult<X>
instead of X
. The API is, therefore, quite modified.Renderer
trait used by the various renderers.Published by lise-henry about 8 years ago
Token
has a new variant, StandaloneImage
. This is used toParser.parse
method now distingues between Image
andStandaloneImage
. Currently, an image is considered "standalone"Token
has a new is_image
method.Published by lise-henry about 8 years ago
nb_char
: since it was only used for french cleaner and forcrowbook
is called from another directory.French
cleaner when a string to clean ended by a--
to -{}-
to avoid tex ligatures.html.display_chapter
now defaults to false
(e.g., by defaultlang
is set to fr
.Published by lise-henry over 8 years ago
Mostly rendering fixes:
html.display_chapter
is set tofalse
.Published by lise-henry over 8 years ago
output.html_dir
will activate this renderer, and specify inhtml_dir.css
allows to override the CSS for this rendering;html_dir.index.html
allows to specify a template for theindex.html
page;html_dir.chapter.html
allows to specify a template for thetex.short
: if set to true, the LaTeX renderer will usearticle
instead of book
as document class, and will use the\maketitle
command for article. This option is by--single
.enable_yaml_blocks
: parsing YAML blocks is no longer activated--single
. This is because you.book
file tohtml.print_css
: allows to specify a stylesheet for media printhtml.display_chapter
: displays one chapter at a time inhtml.script
: allows to specify a custom javascript file forhtml_dir.script
: same thing for multipage HTMLresources.base_path
: by default, Crowbook resolves local links inresources.base_path.images
andresources.base_path.links
, which only activate it for respectivelybase_path
is set. There is also resources.base_path.files
.
(i.e., the directory where the.book
file is) by default.resources.files
: indicate a (whitespace-separated) list ofresources.out_path
: indicate where resources.files
should bedata
, meaning thatdata
directory in the EPUB.lang
lang
value do determinelang
is set to "fr" and standard bullets for other--single
(e.g., crowbook -s tests/test.md
wouldmime_guess
library to guess theBook::new
, new_from_file
, and new_from_markdown_file
options
parameter. To create a book with&[]
.Published by lise-henry over 8 years ago
yaml_rust
, for its--single
allows to give Crowbook a single Markdown file--debug
option to the binary.Logger
struct.--to
argumentPublished by lise-henry over 8 years ago
cargo test
).Published by lise-henry over 8 years ago
Published by lise-henry over 8 years ago
Published by lise-henry over 8 years ago
Published by lise-henry over 8 years ago
--print-template
now allows to print a built-in--list-options
prints out all validset
), their type and default--set
allows to define or override whatever--create
can now be used without specifying a BOOK
, printingstdout
..book
files, withdisplay_toc
allows to display the table of contentstoc_name
) innumbering
now takes an int instead of a boolean,1
:2
: chapters and sectino, ..., 6
: everything).2.3.1
).Book
to use an HashMap of BookOption
s instead ofPublished by lise-henry over 8 years ago