Skip to content

Commit 2a58585

Browse files
authored
chore: update docs, fix ci (#403)
We don't deploy them ourselves, so update flags in ci and for docs.rs builds.
1 parent 01501eb commit 2a58585

File tree

7 files changed

+33
-19
lines changed

7 files changed

+33
-19
lines changed

.github/workflows/ci.yml

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -74,26 +74,16 @@ jobs:
7474
docs:
7575
runs-on: ubuntu-latest
7676
timeout-minutes: 30
77-
permissions:
78-
contents: write
79-
pages: write
8077
steps:
8178
- uses: actions/checkout@v4
8279
- uses: dtolnay/rust-toolchain@nightly
8380
- uses: Swatinem/rust-cache@v2
8481
with:
8582
cache-on-failure: true
86-
- run: cargo doc
83+
- name: Build documentation
84+
run: cargo doc --workspace --all-features --no-deps --document-private-items
8785
env:
88-
RUSTDOCFLAGS: --cfg docsrs -D warnings --show-type-layout --generate-link-to-definition --enable-index-page -Zunstable-options
89-
- name: Deploy documentation
90-
uses: peaceiris/actions-gh-pages@v3
91-
# TODO
92-
if: false && github.event_name == 'push' && github.ref == 'refs/heads/main'
93-
with:
94-
github_token: ${{ secrets.GITHUB_TOKEN }}
95-
publish_dir: target/doc
96-
force_orphan: true
86+
RUSTDOCFLAGS: --cfg docsrs -D warnings -Zunstable-options --show-type-layout --generate-link-to-definition
9787

9888
fmt:
9989
runs-on: ubuntu-latest

crates/ast/Cargo.toml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,11 @@ categories.workspace = true
1414

1515
[package.metadata.docs.rs]
1616
all-features = true
17-
rustdoc-args = ["--cfg", "docsrs"]
17+
rustdoc-args = [
18+
"-Zunstable-options",
19+
"--generate-link-to-definition",
20+
"--show-type-layout",
21+
]
1822

1923
[lints]
2024
workspace = true

crates/data-structures/Cargo.toml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,11 @@ categories.workspace = true
1414

1515
[package.metadata.docs.rs]
1616
all-features = true
17-
rustdoc-args = ["--cfg", "docsrs"]
17+
rustdoc-args = [
18+
"-Zunstable-options",
19+
"--generate-link-to-definition",
20+
"--show-type-layout",
21+
]
1822

1923
[lints]
2024
workspace = true

crates/interface/Cargo.toml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,11 @@ categories.workspace = true
1414

1515
[package.metadata.docs.rs]
1616
all-features = true
17-
rustdoc-args = ["--cfg", "docsrs"]
17+
rustdoc-args = [
18+
"-Zunstable-options",
19+
"--generate-link-to-definition",
20+
"--show-type-layout",
21+
]
1822

1923
[lints]
2024
workspace = true

crates/macros/Cargo.toml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,11 @@ categories.workspace = true
1414

1515
[package.metadata.docs.rs]
1616
all-features = true
17-
rustdoc-args = ["--cfg", "docsrs"]
17+
rustdoc-args = [
18+
"-Zunstable-options",
19+
"--generate-link-to-definition",
20+
"--show-type-layout",
21+
]
1822

1923
[lints]
2024
workspace = true

crates/parse/Cargo.toml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,11 @@ categories.workspace = true
1414

1515
[package.metadata.docs.rs]
1616
all-features = true
17-
rustdoc-args = ["--cfg", "docsrs"]
17+
rustdoc-args = [
18+
"-Zunstable-options",
19+
"--generate-link-to-definition",
20+
"--show-type-layout",
21+
]
1822

1923
[lints]
2024
workspace = true

examples/Cargo.toml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,11 @@ categories.workspace = true
1515

1616
[package.metadata.docs.rs]
1717
all-features = true
18-
rustdoc-args = ["--cfg", "docsrs"]
18+
rustdoc-args = [
19+
"-Zunstable-options",
20+
"--generate-link-to-definition",
21+
"--show-type-layout",
22+
]
1923

2024
[lints]
2125
workspace = true

0 commit comments

Comments
 (0)