Skip to content

Commit ebd360e

Browse files
committed
fixed up deploy job
1 parent 74ce4e0 commit ebd360e

File tree

1 file changed

+12
-9
lines changed

1 file changed

+12
-9
lines changed

.github/workflows/ci-cd.yml

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -48,32 +48,35 @@ jobs:
4848
- uses: codecov/codecov-action@v1
4949
if: ${{ always() }}
5050

51-
5251
deploy:
5352
needs: [test]
5453
runs-on: ubuntu-latest
5554
strategy:
5655
matrix:
5756
python-version: [3.9]
5857
steps:
59-
- uses: actions/checkout@v2
58+
- uses: actions/checkout@v3
6059
with:
6160
submodules: recursive
6261
fetch-depth: 0
63-
- name: Set up Python ${{ matrix.python-version }}
64-
uses: actions/setup-python@v2
62+
- name: Unset header
63+
# checkout@v2 adds a header that makes branch protection report errors
64+
# because the Github action bot is not a collaborator on the repo
65+
run: git config --local --unset http.https://github.com/.extraheader
66+
- name: Set up Python
67+
uses: actions/setup-python@v3
6568
with:
66-
python-version: ${{ matrix.python-version }}
69+
python-version: '3.12'
6770
- name: Install build tools
68-
run: python -m pip install --upgrade pip setuptools wheel twine
71+
run: python3 -m pip install --break-system-packages build twine
6972
- name: Build source and wheel distributions
70-
run: python setup.py sdist bdist_wheel
73+
run: python3 -m build .
7174
- name: Check distributions
7275
run: twine check dist/*
7376
- uses: actions/upload-artifact@v4
7477
with:
75-
name: distributions
76-
path: dist/
78+
name: built
79+
path: /dist
7780
# Deploy on tags if PYPI_API_TOKEN is defined in the repository secrets.
7881
# Secrets are not accessible in the if: condition [0], so set an output variable [1]
7982
# [0] https://github.community/t/16928

0 commit comments

Comments
 (0)