File tree Expand file tree Collapse file tree 3 files changed +48
-49
lines changed Expand file tree Collapse file tree 3 files changed +48
-49
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1
- # name: Publish package
2
1
3
- # on: [ push ]
2
+ name : Publish to PyPi
4
3
5
- # jobs:
6
- # publish:
7
- # if: startsWith(github.ref, 'refs/tags/v')
8
- # runs-on: ubuntu-latest
9
- # steps:
10
- # - uses: actions/checkout@v2
11
- # - uses: actions/setup-python@v2
12
- # with:
13
- # python-version: 3.8
14
- # - uses: abatilo/actions-poetry@v2.0.0
15
- # - run: poetry publish --build
16
- # env:
17
- # POETRY_PYPI_TOKEN_PYPI: ${{ secrets.PYPI_API_TOKEN }}
4
+ on :
5
+ release :
6
+ types : [published]
7
+
8
+ permissions :
9
+ contents : read
10
+
11
+ jobs :
12
+ deploy :
13
+
14
+ runs-on : ubuntu-latest
15
+
16
+ steps :
17
+ - uses : actions/checkout@v3
18
+ - name : Set up Python
19
+ uses : actions/setup-python@v3
20
+ with :
21
+ python-version : ' 3.8'
22
+ - name : Install dependencies
23
+ run : |
24
+ python -m pip install --upgrade pip
25
+ pip install poetry
26
+ poetry export -f requirements.txt --output requirements.txt --without-hashes
27
+ pip install build
28
+ - name : Build package
29
+ run : python -m build
30
+ - name : Publish package
31
+ uses : pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
32
+ with :
33
+ user : __token__
34
+ password : ${{ secrets.PYPI_API_TOKEN }}
Original file line number Diff line number Diff line change @@ -86,3 +86,19 @@ service.resources.add(table)
86
86
87
87
service.render()
88
88
```
89
+
90
+ # New version release process
91
+
92
+ - Update the version in pyproject.toml
93
+
94
+ ```
95
+ # increase the version number as per SemVer standards
96
+ version = "2.13.17"
97
+ ```
98
+
99
+ - Once ready to publish, create a new [github release](https://github.com/epsylabs/serverless-builder/releases)
100
+ - its a good practice to match the tag with the version number as in pyproject.toml
101
+ - Select `set as latest release` checkbox
102
+ - Click `Publish Release` button.
103
+
104
+ - Once published, it will trigger the `release` gh wf and publish the latest package to PyPi.
You can’t perform that action at this time.
0 commit comments