-
-
Notifications
You must be signed in to change notification settings - Fork 2
/
book.toml.bak
180 lines (153 loc) · 7.61 KB
/
book.toml.bak
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
[book]
authors = ["John CD"]
language = "en"
multilingual = false
# src = "src" # the directory with the markdown sources, "src" by default
title = "Rust How-to"
description = "A compendium of links, code snippets, and recipes for the Rust language and ecosystem."
[build]
# build-dir = "book" # the directory where the output is placed, "book" by default
create-missing = false # whether or not to create missing pages
# use-default-preprocessors = true # use the default preprocessors and `index`, true by default
extra-watch-dirs = ["static", "theme", "deps"] # directories to watch for triggering builds
[rust]
edition = "2021" # the default edition for code blocks. Default is "2015"
## PREPROCESSORS -----------------------------------------------------
# # An mdbook preprocessor for defining and optionally hiding private sections and chapters in your book.
# # https://github.com/RealAtix/mdbook-private
[preprocessor.private]
remove = true # Determines whether to remove or retain sections marked as private
style = true # Styles the private sections (when retained) using blockquote CSS.
notice = "WORK IN PROGRESS" # Adds a notice to styled sections at the top right corner.
chapter-prefix = "_" # If the remove option is active, chapters with filenames prefixed with this value will be excluded.
# # Alternative:
# # Adds support for hidden chapters. The hidden chapters can be marked by adding a special Markdown comment: <!--hidden-->
# # https://github.com/ankitrgadiya/mdbook-hide/
# # Enables mdbook-hide, if needed
# [preprocessor.hide]
# hide = true
# # Build a word index via {{i:<text>}}, {{hi:<text>}}...
# # https://github.com/daviddrysdale/mdbook-indexing/tree/main
[preprocessor.indexing]
# use_chapter_names = true
# # Run after removal of hidden chapters
after = [ "private" ]
[preprocessor.indexing.see_instead]
# "unit type" = "`()`" # index entries where the key should point to the value
[preprocessor.indexing.nest_under]
# "generic type" = "generics"
# # mdBook-keeper adds more testing features to mdBook, specifically support for third-party crates, and testing while compiling.
# # https://github.com/tfpk/mdbook-keeper/
# [preprocessor.keeper]
# # command = "mdbook-keeper"
# # NOTE: the file Cargo.toml should exist at this path.
# manifest_dir = "./deps"
# # NOTE: the `debug` folder should exist at this path.
# target_dir = "./target/"
# is_workspace = true
# # build_features = ["first", "second"]
# # Default preprocessor: index
# Convert all chapter files named README.md into index.md. That is to say, all README.md would be rendered to an index file index.html in the rendered book.
#[preprocessor.index]
# # Default preprocessor: links
# # Expands the {{ #playground }}, {{ #include }}, and {{ #rustdoc_include }} handlebars helpers in a chapter
[preprocessor.links]
after = ["private"]
## OUTPUTS --------------------------------------------------------
# # Output as markdown (in addition to HTML) for debugging purposes
# # Enable it as well if you want to use Skeptic for testing (see `deps/build.rs` and `build` in deps/Cargo.toml )
#[output.markdown]
# # See https://rust-lang.github.io/mdBook/format/configuration/renderers.html
[output.html]
# theme = "my-theme"
# default-theme = "light"
# preferred-dark-theme = "navy"
# curly-quotes = true
# mathjax-support = false
# copy-fonts = true
# additional-css = ["custom.css", "custom2.css"]
additional-css = ["theme/custom.css"]
# additional-js = ["custom.js"]
no-section-label = true
git-repository-url = "https://github.com/john-cd/rust_howto"
# git-repository-icon = "fa-github"
edit-url-template = "https://github.com/john-cd/rust_howto/edit/main/{path}"
site-url = "/rust_howto/"
# cname = "john-cd.com"
# input-404 = "not-found.md"
[output.html.print]
enable = true # include support for printable output
page-break = false # insert page-break after each chapter
[output.html.fold]
enable = true # whether or not to enable section folding
level = 0 # the depth to start folding
[output.html.playground]
editable = true # allows editing the source code
# copyable = true # include the copy button for copying code snippets; default: true
# copy-js = true # includes the JavaScript for the code editor
# line-numbers = false # displays line numbers for editable code
# runnable = true # displays a run button for rust code; default: true
# [output.html.code]
# # A prefix string per language (one or more chars).
# # Any line starting with whitespace+prefix is hidden.
# hidelines = { python = "~" }
# [output.html.search]
# enable = true # enables the search feature
# limit-results = 30 # maximum number of search results
# teaser-word-count = 30 # number of words used for a search result teaser
# use-boolean-and = true # multiple search terms must all match
# boost-title = 2 # ranking boost factor for matches in headers
# boost-hierarchy = 1 # ranking boost factor for matches in page names
# boost-paragraph = 1 # ranking boost factor for matches in text
# expand = true # partial words will match longer terms
# heading-split-level = 3 # link results to heading levels
# copy-js = true # include Javascript code for search
# # A backend for mdbook which will check your links for you. For use alongside the built-in HTML renderer.
# # https://github.com/Michael-F-Bryan/mdbook-linkcheck
[output.linkcheck]
# # Should we check links on the internet? Enabling this option adds a
# # non-negligible performance impact
follow-web-links = false
# # Are we allowed to link to files outside of the book's root directory? This
# # may help prevent linking to sensitive files (e.g. "../../../../etc/shadow")
traverse-parent-directories = false
# # If necessary, you can exclude one or more links from being checked with a
# # list of regular expressions. The regex will be applied to the link href (i.e.
# # the `./index.html` in `[some page](./index.html)`) so it can be used to
# # ignore both web and filesystem links.
# #
# # Hint: you can use TOML's raw strings (single quote) to avoid needing to
# # escape things twice.
## Exclude links in e.g. `examples_index.md` for now, to avoid linkcheck warning when hidding sections / pages with `mdbook-private`
exclude = [ '^categories/*' ]
# # The User-Agent to use when sending web requests
# user-agent = "mdbook-linkcheck-0.4.0"
# # The number of seconds a cached result is valid for (12 hrs by default)
# cache-timeout = 43200
# # How should warnings be treated?
# #
# # - "warn" will emit warning messages
# # - "error" treats all warnings as errors, failing the linkcheck
# # - "ignore" will ignore warnings, suppressing diagnostic messages and allowing
# # the linkcheck to continuing
warning-policy = "warn"
# # Extra HTTP headers that must be send to certain web sites
# # in order to link check to succeed.
# #
# # This is a dictionary (map), with keys being regexes
# # matching a set of web sites, and values being an array of
# # the headers.
# [output.linkcheck.http-headers]
# # Any hyperlink that contains this regexp will be sent
# # the "Accept: text/html" header
# 'crates\.io' = ["Accept: text/html"]
# # `mdbook-linkcheck` will interpolate environment variables into your header via
# # $IDENT.
# #
# # If this is not what you want you must escape the `$` symbol, like `\$TOKEN`.
# # `\` itself can also be escaped via `\\`.
# #
# # Note: If interpolation fails, the header will be skipped and the failure will
# # be logged. This can be useful if a particular header isn't always necessary,
# # but may be helpful (e.g. when working with rate limiting).
# #'website\.com' = ["Authorization: Basic $TOKEN"]