@@ -10,27 +10,24 @@ jobs:
10
10
runs-on : ubuntu-latest
11
11
needs : [checks]
12
12
steps :
13
- - uses : actions/checkout@v4
13
+ - uses : actions/checkout@v4
14
14
15
- - name : Install uv
16
- uses : astral-sh/setup-uv@v3
15
+ - name : Install uv
16
+ uses : astral-sh/setup-uv@v3
17
+ with :
18
+ enable-cache : true
17
19
18
- - name : " Set up Python"
19
- uses : actions/setup-python@v5
20
- with :
21
- python-version-file : " .python-version"
20
+ - name : Set up Python 3.12
21
+ run : uv python install 3.12
22
22
23
- - name : Install the project
24
- run : uv sync --frozen --all-extras --dev
23
+ - name : Build
24
+ run : uv build
25
25
26
- - name : Build
27
- run : uv build
28
-
29
- - name : Upload artifacts
30
- uses : actions/upload-artifact@v4
31
- with :
32
- name : release-dists
33
- path : dist/
26
+ - name : Upload artifacts
27
+ uses : actions/upload-artifact@v4
28
+ with :
29
+ name : release-dists
30
+ path : dist/
34
31
35
32
checks :
36
33
uses : ./.github/workflows/shared.yml
@@ -42,14 +39,42 @@ jobs:
42
39
needs :
43
40
- release-build
44
41
permissions :
45
- id-token : write # IMPORTANT: this permission is mandatory for trusted publishing
42
+ id-token : write # IMPORTANT: this permission is mandatory for trusted publishing
46
43
47
44
steps :
48
- - name : Retrieve release distributions
49
- uses : actions/download-artifact@v4
50
- with :
51
- name : release-dists
52
- path : dist/
53
-
54
- - name : Publish package distributions to PyPI
55
- uses : pypa/gh-action-pypi-publish@release/v1
45
+ - name : Retrieve release distributions
46
+ uses : actions/download-artifact@v4
47
+ with :
48
+ name : release-dists
49
+ path : dist/
50
+
51
+ - name : Publish package distributions to PyPI
52
+ uses : pypa/gh-action-pypi-publish@release/v1
53
+
54
+ docs-publish :
55
+ runs-on : ubuntu-latest
56
+ needs : ["pypi-publish"]
57
+ permissions :
58
+ contents : write
59
+ steps :
60
+ - uses : actions/checkout@v4
61
+ - name : Configure Git Credentials
62
+ run : |
63
+ git config user.name github-actions[bot]
64
+ git config user.email 41898282+github-actions[bot]@users.noreply.github.com
65
+
66
+ - name : Install uv
67
+ uses : astral-sh/setup-uv@v3
68
+ with :
69
+ enable-cache : true
70
+
71
+ - run : echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV
72
+ - uses : actions/cache@v4
73
+ with :
74
+ key : mkdocs-material-${{ env.cache_id }}
75
+ path : .cache
76
+ restore-keys : |
77
+ mkdocs-material-
78
+
79
+ - run : uv sync --frozen --group docs
80
+ - run : uv run --no-sync mkdocs gh-deploy --force
0 commit comments