Skip to content

Commit fdfd369

Browse files
authored
Improve .gitignore, enable CI release (#10)
1 parent dbaaa55 commit fdfd369

File tree

4 files changed

+401
-13
lines changed

4 files changed

+401
-13
lines changed

.github/workflows/build.yml

+6-8
Original file line numberDiff line numberDiff line change
@@ -37,11 +37,14 @@ jobs:
3737
version-extraction-override: 'regex:version = "(.*)"'
3838

3939
release:
40-
# TODO: enable once we want to release this package
41-
if: false
42-
# if: github.event_name == 'push' && github.ref_name == 'main' && needs.build.outputs.version-changed == 'true'
40+
name: Publish package
41+
if: github.event_name == 'push' && github.ref_name == 'main' && needs.build.outputs.version-changed == 'true'
4342
needs: [build]
4443
runs-on: ubuntu-latest
44+
permissions:
45+
id-token: write
46+
contents: write
47+
environment: pypi
4548
steps:
4649
- uses: actions/download-artifact@v3
4750
with:
@@ -50,14 +53,9 @@ jobs:
5053
- name: Publish package on TestPyPi
5154
uses: pypa/gh-action-pypi-publish@f8c70e705ffc13c3b4d1221169b84f12a75d6ca8
5255
with:
53-
user: __token__
54-
password: ${{ secrets.TEST_PYPI_TOKEN }}
5556
repository-url: https://test.pypi.org/legacy/
5657
- name: Publish package on PyPi
5758
uses: pypa/gh-action-pypi-publish@f8c70e705ffc13c3b4d1221169b84f12a75d6ca8
58-
with:
59-
user: __token__
60-
password: ${{ secrets.PYPI_TOKEN }}
6159
- uses: actions/checkout@v3
6260
- name: Push v${{ needs.build.outputs.new-version }} tag
6361
run: |

0 commit comments

Comments
 (0)