@@ -2,44 +2,37 @@ name: CI
22
33on :
44 push :
5+ branches-ignore :
6+ - " wip*"
7+ tags :
8+ - " v*"
59 pull_request :
6- release :
7- types : [published]
810 schedule :
911 # Daily at 3:11
1012 - cron : " 11 3 * * *"
11-
12- env :
13- PIP_DISABLE_PIP_VERSION_CHECK : " 1"
14- PIP_NO_PYTHON_VERSION_WARNING : " 1"
13+ workflow_dispatch :
1514
1615jobs :
17- pre-commit :
18- runs-on : ubuntu-latest
19- steps :
20- - uses : actions/checkout@v4
21- - uses : actions/setup-python@v5
22- with :
23- python-version : " 3.x"
24- - uses : pre-commit/action@v3.0.1
25-
2616 list :
2717 runs-on : ubuntu-latest
2818 outputs :
2919 noxenvs : ${{ steps.noxenvs-matrix.outputs.noxenvs }}
3020 steps :
3121 - uses : actions/checkout@v4
32- - name : Set up nox
33- uses : wntrblm/nox@2024.10.09
22+ - name : Set up uv
23+ uses : astral-sh/setup-uv@v5
24+ with :
25+ enable-cache : true
3426 - id : noxenvs-matrix
3527 run : |
3628 echo >>$GITHUB_OUTPUT noxenvs=$(
37- nox --list-sessions --json | jq '[.[].session]'
29+ uvx nox --list-sessions --json | jq '[.[].session]'
3830 )
3931
4032 ci :
4133 needs : list
4234 runs-on : ${{ matrix.os }}
35+
4336 strategy :
4437 fail-fast : false
4538 matrix :
@@ -60,38 +53,40 @@ jobs:
6053 uses : actions/setup-python@v5
6154 with :
6255 python-version : |
63- 3.8
64- 3.9
65- 3.10
6656 3.11
6757 3.12
68- pypy3.10
58+ 3.13
6959 allow-prereleases : true
70- - name : Set up nox
71- uses : wntrblm/nox@2024.10.09
60+
61+ - name : Set up uv
62+ uses : astral-sh/setup-uv@v5
63+ with :
64+ enable-cache : true
65+
7266 - name : Run nox
73- run : nox -s "${{ matrix.noxenv }}"
67+ run : uvx nox -s "${{ matrix.noxenv }}"
7468
7569 packaging :
7670 needs : ci
7771 runs-on : ubuntu-latest
7872 environment :
7973 name : PyPI
8074 url : https://pypi.org/p/sphinx-json-schema-spec
75+
8176 permissions :
8277 contents : write
8378 id-token : write
8479
8580 steps :
8681 - uses : actions/checkout@v4
87- - name : Set up Python
88- uses : actions /setup-python @v5
82+ - name : Set up uv
83+ uses : astral-sh /setup-uv @v5
8984 with :
90- python-version : " 3.x "
91- - name : Install dependencies
92- run : python -m pip install build
93- - name : Create packages
94- run : python -m build .
85+ enable-cache : true
86+
87+ - name : Build our distributions
88+ run : uv run --with 'build[uv]' -m build --installer=uv
89+
9590 - name : Publish to PyPI
9691 if : github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags')
9792 uses : pypa/gh-action-pypi-publish@release/v1
0 commit comments