Skip to content

Commit a096eae

Browse files
committed
fleshed out CI/CD, ready for testing
1 parent e6fac07 commit a096eae

File tree

1 file changed

+14
-13
lines changed

1 file changed

+14
-13
lines changed

.github/workflows/deploy.yml

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
11
name: deploy-to-pypi
22

33
on:
4-
push:
5-
branches: [release]
6-
4+
releases:
5+
types: [released]
76
jobs:
8-
build:
7+
release:
98

109
runs-on: ubuntu-latest
1110
steps:
@@ -15,13 +14,15 @@ jobs:
1514
with:
1615
python-version: '3.7.x' # Version range or exact version of a Python version to use, using SemVer's version range syntax
1716
architecture: 'x64' # optional x64 or x86. Defaults to x64 if not specified
18-
- name: compile
17+
- name: prepare
1918
run: |
20-
pip3 install wheel
21-
python3 setup.py bdist_wheel --universal
22-
- name: Publish a Python distribution to PyPI
23-
uses: pypa/gh-action-pypi-publish@release/v1
24-
with:
25-
user: ${{secrets.PYPI_API_USERNAME}}
26-
password: ${{ secrets.PYPI_API_PASSWORD }}
27-
verbose: true
19+
python -m pip install --upgrade pip
20+
pip install wheel twine setuptools
21+
- name: Package and Upload
22+
env:
23+
ADK_VERSION: ${{github.event.release.tag_name }}
24+
TWINE_USERNAME: ${{secrets.PYPI_USERNAME }}
25+
TWINE_PASSWORD: ${{secrets.PYPI_PASSWORD }}
26+
- run: |
27+
python3 setup.py sdist bdist_wheel --universal
28+
twine upload -r pypi dist/*

0 commit comments

Comments
 (0)