File tree Expand file tree Collapse file tree 3 files changed +19
-0
lines changed
Expand file tree Collapse file tree 3 files changed +19
-0
lines changed Original file line number Diff line number Diff line change 3939 TAG_NAME="${GITHUB_REF##*/}"
4040 echo "tag_name=${TAG_NAME}" >> $GITHUB_OUTPUT
4141
42+ - name : Restore lychee cache
43+ id : restore-cache
44+ uses : actions/cache/restore@v4
45+ with :
46+ path : .lycheecache
47+ key : lychee
48+
4249 # This builds the book in target/guide/.
4350 - name : Build the guide
4451 run : |
4956 # allows lychee to get better rate limits from github
5057 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
5158
59+ - name : Save lychee cache
60+ uses : actions/cache/save@v4
61+ if : ${{ github.ref == 'refs/heads/main' || contains(github.event.pull_request.labels.*.name, 'CI-save-pr-cache') }}
62+ with :
63+ path : .lycheecache
64+ key : ${{ steps.restore-cache.outputs.cache-primary-key }}
65+
5266 # We store the versioned guides on GitHub's gh-pages branch for convenience
5367 # (the full gh-pages branch is pulled in the build-netlify-site step)
5468 - name : Deploy the guide
Original file line number Diff line number Diff line change @@ -28,3 +28,4 @@ coverage.json
2828netlify_build /
2929.nox /
3030.vscode /
31+ .lycheecache
Original file line number Diff line number Diff line change @@ -738,6 +738,8 @@ def check_guide(session: nox.Session):
738738 str (PYO3_GUIDE_SRC ),
739739 * remap_args ,
740740 "--accept=200,429" ,
741+ "--cache" ,
742+ "--max-cache-age=7d" ,
741743 * session .posargs ,
742744 external = True ,
743745 )
@@ -755,6 +757,8 @@ def check_guide(session: nox.Session):
755757 "--accept=200,429" ,
756758 # reduce the concurrency to avoid rate-limit from `pyo3.rs`
757759 "--max-concurrency=32" ,
760+ "--cache" ,
761+ "--max-cache-age=7d" ,
758762 * session .posargs ,
759763 external = True ,
760764 )
You can’t perform that action at this time.
0 commit comments