File tree 2 files changed +20
-22
lines changed
2 files changed +20
-22
lines changed Original file line number Diff line number Diff line change 1
- name : Build & Release
1
+ name : Release
2
2
3
3
on :
4
- release :
5
- types : [published] # Trigger only when a release is published, not when a release is drafted
4
+ push :
6
5
7
6
permissions :
8
7
contents : write # Needed to upload artifacts to the release
9
8
id-token : write # Needed for OIDC PyPI publishing
10
9
11
10
jobs :
12
- build_and_release :
13
-
11
+ build :
14
12
runs-on : ubuntu-latest
15
- environment : publishing
16
-
17
13
steps :
18
14
- uses : actions/checkout@v4
19
15
with :
20
16
fetch-depth : 0
21
- - name : Set up Python
22
- uses : actions/setup-python@v5
17
+ - uses : hynek/build-and-inspect-python-package@v2
18
+
19
+ publish :
20
+ name : Publish to PyPI
21
+ runs-on : ubuntu-latest
22
+ needs : [build]
23
+ environment :
24
+ name : publishing
25
+ url : https://pypi.org/p/meltano-edk
26
+ if : startsWith(github.ref, 'refs/tags/')
27
+ steps :
28
+ - uses : actions/download-artifact@v4
23
29
with :
24
- python-version : ' 3.10'
25
- - name : Install dependencies
26
- run : |
27
- python -m pip install --upgrade pip
28
- pip install poetry
29
- - name : Build package
30
- run : |
31
- poetry self add "poetry-dynamic-versioning[plugin]"
32
- poetry config repositories.testpypi https://test.pypi.org/legacy/
33
- poetry dynamic-versioning --no-cache
34
- poetry build
30
+ name : Packages
31
+ path : dist
35
32
- name : Upload wheel to release
36
33
uses : svenstaro/upload-release-action@v2
37
34
with :
40
37
tag : ${{ github.ref }}
41
38
overwrite : true
42
39
file_glob : true
40
+
43
41
- name : Publish
44
42
Original file line number Diff line number Diff line change @@ -103,8 +103,8 @@ convention = "google"
103
103
104
104
[build-system ]
105
105
requires = [
106
- " poetry-core==1.5.0 " ,
107
- " poetry-dynamic-versioning==0.21.3 " ,
106
+ " poetry-core==1.9 " ,
107
+ " poetry-dynamic-versioning==1.2 " ,
108
108
]
109
109
build-backend = " poetry_dynamic_versioning.backend"
110
110
You can’t perform that action at this time.
0 commit comments