2024-05-30 00:19:46 +00:00
|
|
|
## Books
|
2024-06-24 00:23:39 +00:00
|
|
|
|
2024-05-30 00:19:46 +00:00
|
|
|
This directory contains the source files for Cuprate's various books.
|
|
|
|
|
|
|
|
The source files are edited here, and published in other repositories, see:
|
2024-06-24 00:23:39 +00:00
|
|
|
|
2024-05-30 00:19:46 +00:00
|
|
|
- [Cuprate's architecture book](https://github.com/Cuprate/architecture-book)
|
2024-06-24 00:23:39 +00:00
|
|
|
- [Monero's protocol book](https://github.com/Cuprate/monero-book)
|
2024-06-07 21:04:27 +00:00
|
|
|
- [Cuprate's user book](https://github.com/Cuprate/user-book)
|
2024-05-30 00:19:46 +00:00
|
|
|
|
|
|
|
## Build tools
|
2024-06-24 00:23:39 +00:00
|
|
|
|
|
|
|
Building the book(s) requires [Rust's cargo tool](https://doc.rust-lang.org/cargo/getting-started/installation.html)
|
|
|
|
and [mdBook](https://github.com/rust-lang/mdBook).
|
2024-05-30 00:19:46 +00:00
|
|
|
|
|
|
|
After installing `cargo`, install `mdbook` with:
|
2024-06-24 00:23:39 +00:00
|
|
|
|
2024-05-30 00:19:46 +00:00
|
|
|
```bash
|
|
|
|
cargo install mdbook
|
|
|
|
```
|
|
|
|
|
|
|
|
## Building
|
2024-06-24 00:23:39 +00:00
|
|
|
|
2024-05-30 00:19:46 +00:00
|
|
|
To build a book, go into a book's directory and build:
|
|
|
|
|
|
|
|
```bash
|
2024-06-07 21:04:27 +00:00
|
|
|
# This build Cuprate's user book.
|
|
|
|
cd user/
|
2024-05-30 00:19:46 +00:00
|
|
|
mdbook build
|
|
|
|
```
|
|
|
|
|
2024-06-24 00:23:39 +00:00
|
|
|
The output will be in the `book` subdirectory (`user/book` for the above example). To open the book, you can open it in
|
|
|
|
your web browser like so:
|
|
|
|
|
2024-05-30 00:19:46 +00:00
|
|
|
```bash
|
|
|
|
mdbook build --open
|
|
|
|
```
|