Skip to content

Commit bbfa960

Browse files
committed
Pass args via env for maturin upload
1 parent b20e304 commit bbfa960

1 file changed

Lines changed: 20 additions & 4 deletions

File tree

.github/workflows/test-release.yaml

Lines changed: 20 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,11 @@ jobs:
2424
uses: PyO3/maturin-action@v1
2525
with:
2626
command: upload
27-
args: --repository-url https://test.pypi.org/legacy/ --username __token__ --password ${{ secrets.TEST_PYPI_TOKEN }} --skip-existing dist/*
27+
args: --skip-existing dist/*
28+
env:
29+
MATURIN_REPOSITORY_URL: https://test.pypi.org/legacy/
30+
MATURIN_USERNAME: __token__
31+
MATURIN_PASSWORD: ${{ secrets.TEST_PYPI_TOKEN }}
2832

2933
windows:
3034
runs-on: windows-latest
@@ -45,7 +49,11 @@ jobs:
4549
uses: PyO3/maturin-action@v1
4650
with:
4751
command: upload
48-
args: --repository-url https://test.pypi.org/legacy/ --username __token__ --password ${{ secrets.TEST_PYPI_TOKEN }} --skip-existing dist/*
52+
args: --skip-existing dist/*
53+
env:
54+
MATURIN_REPOSITORY_URL: https://test.pypi.org/legacy/
55+
MATURIN_USERNAME: __token__
56+
MATURIN_PASSWORD: ${{ secrets.TEST_PYPI_TOKEN }}
4957

5058
macos:
5159
runs-on: macos-latest
@@ -66,7 +74,11 @@ jobs:
6674
uses: PyO3/maturin-action@v1
6775
with:
6876
command: upload
69-
args: --repository-url https://test.pypi.org/legacy/ --username __token__ --password ${{ secrets.TEST_PYPI_TOKEN }} --skip-existing dist/*
77+
args: --skip-existing dist/*
78+
env:
79+
MATURIN_REPOSITORY_URL: https://test.pypi.org/legacy/
80+
MATURIN_USERNAME: __token__
81+
MATURIN_PASSWORD: ${{ secrets.TEST_PYPI_TOKEN }}
7082

7183
sdist:
7284
runs-on: ubuntu-latest
@@ -83,4 +95,8 @@ jobs:
8395
uses: PyO3/maturin-action@v1
8496
with:
8597
command: upload
86-
args: --repository-url https://test.pypi.org/legacy/ --username __token__ --password ${{ secrets.TEST_PYPI_TOKEN }} --skip-existing dist/*
98+
args: --skip-existing dist/*
99+
env:
100+
MATURIN_REPOSITORY_URL: https://test.pypi.org/legacy/
101+
MATURIN_USERNAME: __token__
102+
MATURIN_PASSWORD: ${{ secrets.TEST_PYPI_TOKEN }}

0 commit comments

Comments
 (0)