blob: 08644287db102adc71035e73cd6ad544fa2be7b1 [file] [log] [blame] [view]
Serge Bazanskiaad79482021-07-02 17:40:36 +02001Metropolis Handbook
2===
3
4This directory contains the sources of the Metropolis Handbook end-user documentation.
5
6Layout
7---
8
9Everything within `//monogon/handbook/src` will be used to generate documentation with [mdbook](https://rust-lang.github.io/mdBook/format/index.html).
10
11Compared to upstream mdbook we do not have a static `book.toml` file, one is instead generated as part of the build process. See the definition of the `//metropolis/handbook` target to change some of the options.
12
13Building
14---
15
16 bazel build //metropolis/handbook
17
18Then, you can visit the following file in your browser:
19
20 bazel-bin/metropolis/handbook/handbook/index.html
21
22To view the built documentation.
23
24Interactive editing
25---
26
27For faster edit/check loops of the handbook, you can use `ibazel`:
28
29 ibazel build //metropolis/handbook
30
31This will automatically rebuild the handbook any time some source changes.
32
33You will still need to manually refresh your browser to see any changes. This could be made better, if needed, by injecting some [ibazel-compatible live reload javascript](https://github.com/bazelbuild/bazel-watcher/blob/84cab6f15f64850fb972ea88701e634c8b611301/example_client/example_client.go#L24) to automatically reload the page on changes, or by adding a target which launches `mdbook serve`.
34
35Publishing
36---
37
38We currently do not build the handbook automatically and/or publish it anywhere.