Skip to content

Commit 8987851

Browse files
committed
docs: Switch the guide to use smart punctuation.
1 parent 8344465 commit 8987851

File tree

13 files changed

+40
-39
lines changed

13 files changed

+40
-39
lines changed

guide/book.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ language = "en"
88
edition = "2018"
99

1010
[output.html]
11+
smart-punctuation = true
1112
mathjax-support = true
1213
site-url = "/mdBook/"
1314
git-repository-url = "https://github.com/rust-lang/mdBook/tree/master/guide"

guide/src/cli/README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ After you have [installed](../guide/installation.md) `mdbook`, you can run the `
55

66
This following sections provide in-depth information on the different commands available.
77

8-
* [`mdbook init <directory>`](init.md) Creates a new book with minimal boilerplate to start with.
9-
* [`mdbook build`](build.md) Renders the book.
10-
* [`mdbook watch`](watch.md) Rebuilds the book any time a source file changes.
11-
* [`mdbook serve`](serve.md) Runs a web server to view the book, and rebuilds on changes.
12-
* [`mdbook test`](test.md) Tests Rust code samples.
13-
* [`mdbook clean`](clean.md) Deletes the rendered output.
14-
* [`mdbook completions`](completions.md) Support for shell auto-completion.
8+
* [`mdbook init <directory>`](init.md) --- Creates a new book with minimal boilerplate to start with.
9+
* [`mdbook build`](build.md) --- Renders the book.
10+
* [`mdbook watch`](watch.md) --- Rebuilds the book any time a source file changes.
11+
* [`mdbook serve`](serve.md) --- Runs a web server to view the book, and rebuilds on changes.
12+
* [`mdbook test`](test.md) --- Tests Rust code samples.
13+
* [`mdbook clean`](clean.md) --- Deletes the rendered output.
14+
* [`mdbook completions`](completions.md) --- Support for shell auto-completion.

guide/src/cli/build.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,12 @@ root instead of the current working directory.
2222
mdbook build path/to/book
2323
```
2424

25-
#### --open
25+
#### `--open`
2626

2727
When you use the `--open` (`-o`) flag, mdbook will open the rendered book in
2828
your default web browser after building it.
2929

30-
#### --dest-dir
30+
#### `--dest-dir`
3131

3232
The `--dest-dir` (`-d`) option allows you to change the output directory for the
3333
book. Relative paths are interpreted relative to the book's root directory. If

guide/src/cli/clean.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ root instead of the current working directory.
1616
mdbook clean path/to/book
1717
```
1818

19-
#### --dest-dir
19+
#### `--dest-dir`
2020

2121
The `--dest-dir` (`-d`) option allows you to override the book's output
2222
directory, which will be deleted by this command. Relative paths are interpreted
@@ -27,4 +27,4 @@ value of the `build.build-dir` key in `book.toml`, or to `./book`.
2727
mdbook clean --dest-dir=path/to/book
2828
```
2929

30-
`path/to/book` could be absolute or relative.
30+
`path/to/book` could be absolute or relative.

guide/src/cli/init.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,15 +45,15 @@ instead of the current working directory.
4545
mdbook init path/to/book
4646
```
4747

48-
#### --theme
48+
#### `--theme`
4949

5050
When you use the `--theme` flag, the default theme will be copied into a
5151
directory called `theme` in your source directory so that you can modify it.
5252

5353
The theme is selectively overwritten, this means that if you don't want to
5454
overwrite a specific file, just delete it and the default file will be used.
5555

56-
#### --title
56+
#### `--title`
5757

5858
Specify a title for the book. If not supplied, an interactive prompt will ask for
5959
a title.
@@ -62,7 +62,7 @@ a title.
6262
mdbook init --title="my amazing book"
6363
```
6464

65-
#### --ignore
65+
#### `--ignore`
6666

6767
Create a `.gitignore` file configured to ignore the `book` directory created when [building] a book.
6868
If not supplied, an interactive prompt will ask whether it should be created.
@@ -77,6 +77,6 @@ mdbook init --ignore=git
7777

7878
[building]: build.md
7979

80-
#### --force
80+
#### `--force`
8181

8282
Skip the prompts to create a `.gitignore` and for the title for the book.

guide/src/cli/serve.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,12 +32,12 @@ The `serve` hostname defaults to `localhost`, and the port defaults to `3000`. E
3232
mdbook serve path/to/book -p 8000 -n 127.0.0.1
3333
```
3434

35-
#### --open
35+
#### `--open`
3636

3737
When you use the `--open` (`-o`) flag, mdbook will open the book in your
3838
default web browser after starting the server.
3939

40-
#### --dest-dir
40+
#### `--dest-dir`
4141

4242
The `--dest-dir` (`-d`) option allows you to change the output directory for the
4343
book. Relative paths are interpreted relative to the book's root directory. If

guide/src/cli/test.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ instead of the current working directory.
3737
mdbook test path/to/book
3838
```
3939

40-
#### --library-path
40+
#### `--library-path`
4141

4242
The `--library-path` (`-L`) option allows you to add directories to the library
4343
search path used by `rustdoc` when it builds and tests the examples. Multiple
@@ -54,14 +54,14 @@ mdbook test my-book -L target/debug/deps/
5454
See the `rustdoc` command-line [documentation](https://doc.rust-lang.org/rustdoc/command-line-arguments.html#-l--library-path-where-to-look-for-dependencies)
5555
for more information.
5656

57-
#### --dest-dir
57+
#### `--dest-dir`
5858

5959
The `--dest-dir` (`-d`) option allows you to change the output directory for the
6060
book. Relative paths are interpreted relative to the book's root directory. If
6161
not specified it will default to the value of the `build.build-dir` key in
6262
`book.toml`, or to `./book`.
6363

64-
#### --chapter
64+
#### `--chapter`
6565

6666
The `--chapter` (`-c`) option allows you to test a specific chapter of the
6767
book using the chapter name or the relative path to the chapter.

guide/src/cli/watch.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,12 @@ root instead of the current working directory.
1515
mdbook watch path/to/book
1616
```
1717

18-
#### --open
18+
#### `--open`
1919

2020
When you use the `--open` (`-o`) option, mdbook will open the rendered book in
2121
your default web browser.
2222

23-
#### --dest-dir
23+
#### `--dest-dir`
2424

2525
The `--dest-dir` (`-d`) option allows you to change the output directory for the
2626
book. Relative paths are interpreted relative to the book's root directory. If

guide/src/continuous-integration.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -51,13 +51,13 @@ cargo install mdbook --no-default-features --features search --vers "^0.4" --loc
5151

5252
This includes several recommended options:
5353

54-
* `--no-default-features` Disables features like the HTTP server used by `mdbook serve` that is likely not needed on CI.
54+
* `--no-default-features` --- Disables features like the HTTP server used by `mdbook serve` that is likely not needed on CI.
5555
This will speed up the build time significantly.
56-
* `--features search` Disabling default features means you should then manually enable features that you want, such as the built-in [search] capability.
57-
* `--vers "^0.4"` This will install the most recent version of the `0.4` series.
56+
* `--features search` --- Disabling default features means you should then manually enable features that you want, such as the built-in [search] capability.
57+
* `--vers "^0.4"` --- This will install the most recent version of the `0.4` series.
5858
However, versions after like `0.5.0` won't be installed, as they may break your build.
5959
Cargo will automatically upgrade mdBook if you have an older version already installed.
60-
* `--locked` This will use the dependencies that were used when mdBook was released.
60+
* `--locked` --- This will use the dependencies that were used when mdBook was released.
6161
Without `--locked`, it will use the latest version of all dependencies, which may include some fixes since the last release, but may also (rarely) cause build problems.
6262

6363
You will likely want to investigate caching options, as building mdBook can be somewhat slow.

guide/src/format/configuration/general.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ edition = "2015" # the default edition for code blocks
7272
```
7373

7474
- **edition**: Rust edition to use by default for the code snippets. Default
75-
is "2015". Individual code blocks can be controlled with the `edition2015`,
75+
is `"2015"`. Individual code blocks can be controlled with the `edition2015`,
7676
`edition2018` or `edition2021` annotations, such as:
7777

7878
~~~text

0 commit comments

Comments
 (0)