Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(docs): update example books #107

Merged
merged 1 commit into from
Jul 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion books/cargo
Submodule cargo updated 2033 files
2 changes: 1 addition & 1 deletion books/mdBook
Submodule mdBook updated 55 files
+4 −10 .github/workflows/deploy.yml
+36 −14 .github/workflows/main.yml
+71 −0 CHANGELOG.md
+1 −1 CONTRIBUTING.md
+439 −394 Cargo.lock
+8 −7 Cargo.toml
+13 −0 ci/install-rust.sh
+0 −4 ci/make-release-asset.sh
+1 −0 guide/book.toml
+7 −7 guide/src/cli/README.md
+7 −0 guide/src/cli/arg-watcher.md
+4 −4 guide/src/cli/build.md
+2 −2 guide/src/cli/clean.md
+4 −4 guide/src/cli/init.md
+4 −2 guide/src/cli/serve.md
+3 −3 guide/src/cli/test.md
+3 −2 guide/src/cli/watch.md
+5 −5 guide/src/continuous-integration.md
+1 −1 guide/src/for_developers/backends.md
+1 −1 guide/src/format/configuration/general.md
+8 −6 guide/src/format/configuration/renderers.md
+3 −3 guide/src/format/markdown.md
+8 −8 guide/src/format/mdbook.md
+6 −5 guide/src/format/summary.md
+3 −3 guide/src/format/theme/index-hbs.md
+1 −0 guide/src/format/theme/syntax-highlighting.md
+1 −1 guide/src/guide/installation.md
+12 −1 src/book/book.rs
+46 −21 src/book/mod.rs
+42 −24 src/book/summary.rs
+14 −0 src/cmd/command_prelude.rs
+7 −18 src/cmd/serve.rs
+1 −1 src/cmd/test.rs
+31 −180 src/cmd/watch.rs
+189 −0 src/cmd/watch/native.rs
+386 −0 src/cmd/watch/poller.rs
+53 −17 src/config.rs
+10 −5 src/renderer/html_handlebars/hbs_renderer.rs
+7 −7 src/renderer/html_handlebars/helpers/toc.rs
+41 −13 src/renderer/html_handlebars/search.rs
+0 −2 src/theme/css/chrome.css
+0 −2 src/theme/css/general.css
+1 −0 src/theme/highlight.js
+0 −1 src/theme/mod.rs
+1 −1 src/theme/searcher/searcher.js
+19 −53 src/utils/fs.rs
+35 −14 src/utils/mod.rs
+1 −0 test_book/src/SUMMARY.md
+42 −0 test_book/src/individual/mathjax.md
+1 −0 test_book/src/languages/README.md
+9 −0 test_book/src/languages/highlight.md
+15 −17 tests/alternative_backends.rs
+4 −0 tests/dummy_book/src/conclusion.md
+6 −5 tests/rendered_output.rs
+242 −4 tests/searchindex_fixture.json
2 changes: 1 addition & 1 deletion books/nomicon
2 changes: 1 addition & 1 deletion books/rust-book
Submodule rust-book updated 382 files
2 changes: 1 addition & 1 deletion books/rust-reference
Submodule rust-reference updated 54 files
+16 −1 .github/workflows/main.yml
+5 −5 CONTRIBUTING.md
+36 −26 README.md
+2 −68 STYLE.md
+3 −0 book.toml
+148 −0 docs/authoring.md
+2 −0 rust-toolchain.toml
+51 −44 src/attributes.md
+109 −99 src/attributes/codegen.md
+29 −0 src/attributes/debugger.md
+205 −14 src/attributes/diagnostics.md
+52 −15 src/attributes/type_system.md
+1 −1 src/behavior-considered-undefined.md
+4 −3 src/comments.md
+18 −0 src/conditional-compilation.md
+3 −1 src/const_eval.md
+14 −44 src/crates-and-source-files.md
+2 −0 src/expressions.md
+60 −0 src/expressions/block-expr.md
+262 −6 src/expressions/literal-expr.md
+27 −8 src/expressions/operator-expr.md
+3 −0 src/expressions/path-expr.md
+16 −1 src/expressions/underscore-expr.md
+3 −3 src/inline-assembly.md
+53 −1 src/input-format.md
+16 −9 src/items.md
+2 −2 src/items/constant-items.md
+0 −5 src/items/extern-crates.md
+10 −8 src/items/external-blocks.md
+5 −4 src/items/functions.md
+4 −1 src/items/generics.md
+3 −1 src/items/unions.md
+2 −2 src/lifetime-elision.md
+7 −2 src/linkage.md
+5 −3 src/macros-by-example.md
+7 −7 src/names.md
+1 −1 src/names/namespaces.md
+5 −5 src/names/preludes.md
+348 −1 src/names/scopes.md
+8 −3 src/paths.md
+51 −23 src/patterns.md
+2 −2 src/procedural-macros.md
+1 −0 src/special-types-and-traits.md
+2 −1 src/statements.md
+49 −57 src/tokens.md
+2 −1 src/trait-bounds.md
+7 −4 src/type-layout.md
+4 −4 src/types.md
+1 −4 src/types/impl-trait.md
+1 −0 src/types/tuple.md
+21 −12 style-check/Cargo.lock
+1 −1 style-check/Cargo.toml
+10 −1 style-check/src/main.rs
+166 −0 theme/reference.css
2 changes: 1 addition & 1 deletion books/rustc-dev-guide
Submodule rustc-dev-guide updated 118 files
10 changes: 10 additions & 0 deletions src/snapshots/mdbook_pandoc__tests__cargo_book.snap
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ DEBUG mdbook::book: Running the links preprocessor.
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../reference/conditional-compilation.html#target_arch' in chapter 'reference/environment-variables.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../reference/conditional-compilation.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../reference/conditional-compilation.html#target_vendor' in chapter 'reference/environment-variables.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../reference/conditional-compilation.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../reference/conditional-compilation.html#target_env' in chapter 'reference/environment-variables.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../reference/conditional-compilation.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../reference/conditional-compilation.html#target_abi' in chapter 'reference/environment-variables.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../reference/conditional-compilation.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../reference/conditional-compilation.html#target_pointer_width' in chapter 'reference/environment-variables.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../reference/conditional-compilation.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../reference/conditional-compilation.html#target_endian' in chapter 'reference/environment-variables.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../reference/conditional-compilation.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../reference/conditional-compilation.html#target_feature' in chapter 'reference/environment-variables.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../reference/conditional-compilation.html'
Expand All @@ -95,6 +96,11 @@ DEBUG mdbook::book: Running the links preprocessor.
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../rustc/command-line-arguments.md#option-l-search-path' in chapter 'reference/build-scripts.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../rustc/command-line-arguments.md'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../rustc/command-line-arguments.md#option-cfg' in chapter 'reference/build-scripts.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../rustc/command-line-arguments.md'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../reference/conditional-compilation.md' in chapter 'reference/build-scripts.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../reference/conditional-compilation.md'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../rustc/lints/listing/warn-by-default.md#unexpected-cfgs' in chapter 'reference/build-scripts.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../rustc/lints/listing/warn-by-default.md'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../rustc/lints/listing/warn-by-default.md#unexpected-cfgs' in chapter 'reference/build-scripts.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../rustc/lints/listing/warn-by-default.md'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../rustc/command-line-arguments.md#option-check-cfg' in chapter 'reference/build-scripts.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../rustc/command-line-arguments.md'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../rustc/check-cfg.html' in chapter 'reference/build-scripts.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../rustc/check-cfg.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../rustc/command-line-arguments.md#option-cfg' in chapter 'reference/build-scripts.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../rustc/command-line-arguments.md'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../std/macro.env.html' in chapter 'reference/build-scripts.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../std/macro.env.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../rustc/codegen-options/index.md#link-arg' in chapter 'reference/build-scripts.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../rustc/codegen-options/index.md'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../std/macro.include.html' in chapter 'reference/build-script-examples.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../std/macro.include.html'
Expand Down Expand Up @@ -162,11 +168,15 @@ DEBUG mdbook::book: Running the links preprocessor.
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../rustc/lints/listing/warn-by-default.html#unused-unsafe' in chapter 'reference/semver.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../rustc/lints/listing/warn-by-default.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../rustc/lints/levels.html#capping-lints' in chapter 'reference/semver.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../rustc/lints/levels.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../book/appendix-07-nightly-rust.html' in chapter 'reference/unstable.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../book/appendix-07-nightly-rust.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../rustc/lints/listing/warn-by-default.html#exported-private-dependencies' in chapter 'reference/unstable.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../rustc/lints/listing/warn-by-default.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../edition-guide/index.html' in chapter 'reference/unstable.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../edition-guide/index.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../edition-guide/index.html' in chapter 'reference/unstable.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/reference/../../edition-guide/index.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../edition-guide/index.html' in chapter 'appendix/glossary.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/appendix/../../edition-guide/index.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../reference/attributes/codegen.html#the-target_feature-attribute' in chapter 'appendix/glossary.md', linking to hosted HTML book at 'https://doc.rust-lang.org/cargo/appendix/../../reference/attributes/codegen.html'
DEBUG mdbook_pandoc::pandoc::renderer: Running pandoc
[WARNING] [makePDF] LaTeX Warning: Hyper reference
`book__pdf__src__commands__cargo-updatemd__option-cargo-update---precise'
on $PAGE undefined on input $LINE.
[WARNING] [makePDF] LaTeX Warning: Hyper reference
`book__pdf__src__commands__cargomd__option-cargo---offline'
on $PAGE undefined on input $LINE.
Expand Down
2 changes: 2 additions & 0 deletions src/snapshots/mdbook_pandoc__tests__nomicon.snap
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ expression: logs
INFO mdbook_pandoc::preprocess: Failed to resolve link '../std/collections/struct.BTreeMap.html' in chapter 'safe-unsafe-meaning.md', linking to hosted HTML book at 'https://doc.rust-lang.org/nomicon/../std/collections/struct.BTreeMap.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../reference/attributes/codegen.html#the-target_feature-attribute' in chapter 'what-unsafe-does.md', linking to hosted HTML book at 'https://doc.rust-lang.org/nomicon/../reference/attributes/codegen.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../std/ptr/struct.NonNull.html' in chapter 'what-unsafe-does.md', linking to hosted HTML book at 'https://doc.rust-lang.org/nomicon/../std/ptr/struct.NonNull.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../reference/behavior-considered-undefined.html' in chapter 'what-unsafe-does.md', linking to hosted HTML book at 'https://doc.rust-lang.org/nomicon/../reference/behavior-considered-undefined.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../reference/behavior-not-considered-unsafe.html' in chapter 'what-unsafe-does.md', linking to hosted HTML book at 'https://doc.rust-lang.org/nomicon/../reference/behavior-not-considered-unsafe.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../reference/type-layout.html' in chapter 'data.md', linking to hosted HTML book at 'https://doc.rust-lang.org/nomicon/../reference/type-layout.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../std/primitive.slice.html' in chapter 'exotic-sizes.md', linking to hosted HTML book at 'https://doc.rust-lang.org/nomicon/../std/primitive.slice.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../std/primitive.str.html' in chapter 'exotic-sizes.md', linking to hosted HTML book at 'https://doc.rust-lang.org/nomicon/../std/primitive.str.html'
Expand Down
7 changes: 4 additions & 3 deletions src/snapshots/mdbook_pandoc__tests__rust_book.snap
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
source: src/lib.rs
expression: logs
---
WARN mdbook::preprocess::cmd: The command wasn't found, is the "trpl-listing" preprocessor installed?
WARN mdbook::preprocess::cmd: Command: mdbook-trpl-listing
WARN mdbook::preprocess::cmd: The command wasn't found, is the "trpl-note" preprocessor installed?
WARN mdbook::preprocess::cmd: Command: mdbook-trpl-note
INFO mdbook::book: Running the pandoc backend
INFO mdbook_pandoc::preprocess: Failed to resolve link '../std/prelude/index.html' in chapter 'ch02-00-guessing-game-tutorial.md', linking to hosted HTML book at 'https://doc.rust-lang.org/book/../std/prelude/index.html'
INFO mdbook_pandoc::preprocess: Failed to resolve link '../std/string/struct.String.html' in chapter 'ch02-00-guessing-game-tutorial.md', linking to hosted HTML book at 'https://doc.rust-lang.org/book/../std/string/struct.String.html'
Expand Down Expand Up @@ -61,11 +65,8 @@ expression: logs
[WARNING] Missing character: There is no ك (U+0643) (U+0643) in font NotoSansMono:mode=node;script
[WARNING] Missing character: There is no م (U+0645) (U+0645) in font NotoSansMono:mode=node;script
[WARNING] Missing character: There is no ש (U+05E9) (U+05E9) in font NotoSansMono:mode=node;script
[WARNING] Missing character: There is no ָ (U+05B8) (U+05B8) in font NotoSansMono:mode=node;script
[WARNING] Missing character: There is no ׁ (U+05C1) (U+05C1) in font NotoSansMono:mode=node;script
[WARNING] Missing character: There is no ל (U+05DC) (U+05DC) in font NotoSansMono:mode=node;script
[WARNING] Missing character: There is no ו (U+05D5) (U+05D5) in font NotoSansMono:mode=node;script
[WARNING] Missing character: There is no ֹ (U+05B9) (U+05B9) in font NotoSansMono:mode=node;script
[WARNING] Missing character: There is no ם (U+05DD) (U+05DD) in font NotoSansMono:mode=node;script
[WARNING] Missing character: There is no न (U+0928) (U+0928) in font NotoSansMono:mode=node;scrip
[WARNING] Missing character: There is no म (U+092E) (U+092E) in font NotoSansMono:mode=node;scrip
Expand Down
1 change: 0 additions & 1 deletion src/snapshots/mdbook_pandoc__tests__rust_by_example.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ source: src/lib.rs
expression: logs
---
INFO mdbook::book: Running the pandoc backend
INFO mdbook_pandoc::preprocess: Failed to resolve link '../../reference/inline-assembly.html#abi-clobbers' in chapter 'unsafe/asm.md', linking to hosted HTML book at 'https://doc.rust-lang.org/rust-by-example/unsafe/../../reference/inline-assembly.html'
[WARNING] [makePDF] LaTeX Warning: Hyper reference
`book__pdf__src__std__result__question_markmd' on $PAGE
undefined on input $LINE.
Expand Down
Loading
Loading