Skip to content

Commit 3aff1ba

Browse files
authored
Update release.yaml
this is related to PyPI 2FA
1 parent 6b086e0 commit 3aff1ba

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

.github/workflows/release.yaml

+8-4
Original file line numberDiff line numberDiff line change
@@ -6,19 +6,23 @@ on: [push]
66

77
jobs:
88
release:
9+
name: Upload release to PyPI
910
runs-on: ubuntu-latest
11+
environment:
12+
name: pypi
13+
url: https://pypi.org/p/cmocean
14+
permissions:
15+
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing
1016
steps:
1117
- uses: actions/checkout@v4
1218
- uses: actions/setup-python@v5
1319
- name: Install dependencies
1420
run: |
15-
python -m pip install -U pip wheel "setuptools<66.0.0" setuptools-scm twine
21+
python -m pip install -U pip wheel
22+
# python -m pip install -U pip wheel "setuptools<66.0.0" setuptools-scm twine
1623
- name: Build distributions
1724
run: python setup.py sdist bdist_wheel
1825

1926
- name: Publish to PyPI
2027
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
2128
uses: pypa/gh-action-pypi-publish@release/v1
22-
with:
23-
user: ${{ secrets.PYPI_USERNAME }}
24-
password: ${{ secrets.PYPI_PASSWORD }}

0 commit comments

Comments
 (0)