File tree Expand file tree Collapse file tree 4 files changed +35
-19
lines changed Expand file tree Collapse file tree 4 files changed +35
-19
lines changed Original file line number Diff line number Diff line change 6
6
pull_request :
7
7
branches : [main]
8
8
9
+ permissions : {}
10
+
9
11
jobs :
10
12
linux :
11
13
name : " sphinx v${{matrix.sphinx-version}} py${{matrix.python-version}}"
33
35
uses : actions/checkout@v4
34
36
with :
35
37
fetch-depth : 0
38
+ persist-credentials : false
36
39
37
40
- name : setup python
38
41
uses : actions/setup-python@v5
Original file line number Diff line number Diff line change 8
8
schedule :
9
9
- cron : " 0 0 * * *"
10
10
11
+ permissions : {}
12
+
11
13
jobs :
12
14
detect-ci-trigger :
13
15
name : detect upstream-dev ci trigger
21
23
- uses : actions/checkout@v4
22
24
with :
23
25
fetch-depth : 2
26
+ persist-credentials : false
24
27
-
uses :
xarray-contrib/[email protected]
25
28
id : detect-trigger
26
29
with :
52
55
with :
53
56
# need to fetch all tags to get a correct version
54
57
fetch-depth : 0 # fetch all branches and tags
58
+ persist-credentials : false
55
59
56
60
- name : setup python
57
61
uses : actions/setup-python@v5
@@ -96,9 +100,15 @@ jobs:
96
100
&& github.event_name == 'schedule'
97
101
&& github.repository == 'xarray-contrib/sphinx-autosummary-accessors'
98
102
&& needs.upstream-dev.outputs.artifacts_availability == 'true'
103
+
104
+ permissions :
105
+ issues : write
106
+
99
107
steps :
100
108
- name : checkout the repository
101
109
uses : actions/checkout@v4
110
+ with :
111
+ persist-credentials : false
102
112
- name : setup python
103
113
uses : actions/setup-python@v5
104
114
with :
Original file line number Diff line number Diff line change 1
- name : Upload package to PyPI
1
+ name : Upload Python Package on PyPI
2
2
3
3
on :
4
4
release :
5
- types : [created ]
5
+ types : [published ]
6
6
7
7
jobs :
8
- publish :
9
- name : Publish to PyPI
8
+ deploy :
10
9
runs-on : ubuntu-latest
10
+ environment :
11
+ name : pypi
12
+ url : https://pypi.org/p/sphinx-autosummary-accessors
13
+ permissions :
14
+ id-token : write
11
15
steps :
12
- - uses : actions/checkout@v4
16
+ - name : Checkout
17
+ uses : actions/checkout@v4
18
+ with :
19
+ persist-credentials : false
13
20
- name : Set up Python
14
21
uses : actions/setup-python@v5
15
22
with :
16
23
python-version : " 3.x"
17
- - name : Install dependencies
18
- run : |
19
- python -m pip install --upgrade pip build twine
20
- - name : Build
21
- run : |
22
- python -m build --sdist --wheel --outdir dist/ .
23
- - name : Check the built archives
24
- run : |
25
- twine check dist/*
26
- - name : Publish to PyPI
24
+ - name : Install publish dependencies
25
+ run : python -m pip install build
26
+ - name : Build package
27
+ run : python -m build . -o dist
28
+ - name : Publish package to PyPI
27
29
uses : pypa/gh-action-pypi-publish@76f52bc884231f62b9a034ebfe128415bbaabdfc
28
30
with :
29
- user : __token__
30
- password : ${{ secrets.pypi_token }}
31
- repository_url : https://upload.pypi.org/legacy/
32
- verify_metadata : true
31
+ packages-dir : dist
Original file line number Diff line number Diff line change 31
31
rev : 25.1.0
32
32
hooks :
33
33
- id : black
34
+ - repo : https://github.com/woodruffw/zizmor-pre-commit
35
+ rev : v1.4.1
36
+ hooks :
37
+ - id : zizmor
You can’t perform that action at this time.
0 commit comments