Skip to content

Commit 566124f

Browse files
JohnTitortshepang
authored andcommitted
Use ephemeral PAT for linkcheck
Signed-off-by: Yuki Okushi <[email protected]>
1 parent c166632 commit 566124f

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ jobs:
2020
MDBOOK_TOC_VERSION: 0.9.0
2121
DEPLOY_DIR: book/html
2222
BASE_SHA: ${{ github.event.pull_request.base.sha }}
23+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2324
steps:
2425
- uses: actions/checkout@v3
2526
with:

book.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,9 @@ exclude = [
4040
cache-timeout = 86400
4141
warning-policy = "error"
4242

43+
[output.linkcheck.http-headers]
44+
'github\.com' = ["Accept: application/vnd.github+json", "Authorization: Bearer $GITHUB_TOKEN"]
45+
4346
[output.html.redirect]
4447
"/compiletest.html" = "tests/compiletest.html"
4548
"/diagnostics/sessiondiagnostic.html" = "diagnostics/diagnostic-structs.html"

0 commit comments

Comments
 (0)