Skip to content

Commit 8d2e13e

Browse files
committed
update release action to publish to pypi
1 parent 684b22d commit 8d2e13e

File tree

2 files changed

+13
-11
lines changed

2 files changed

+13
-11
lines changed

.github/workflows/release.yml

+12-10
Original file line numberDiff line numberDiff line change
@@ -10,19 +10,21 @@ jobs:
1010
build:
1111
if: ${{ github.repository == 'Netflix/spectator-py' }}
1212
runs-on: ubuntu-latest
13-
strategy:
14-
matrix:
15-
python-version: [3.5, 3.6, 3.7, 3.8, 3.9]
1613
steps:
1714
- uses: actions/checkout@v2
18-
- name: Set up Python ${{ matrix.python-version }}
15+
- name: Set up Python 3.9
1916
uses: actions/setup-python@v2
2017
with:
21-
python-version: ${{ matrix.python-version }}
22-
- name: Install dependencies
18+
python-version: 3.9
19+
- name: Install pypa/build
2320
run: |
2421
python -m pip install --upgrade pip
25-
pip install tox
26-
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
27-
- name: Run Tox
28-
run: tox -e py
22+
python -m pip install build --user
23+
- name: Build a binary wheel and a source tarball
24+
run: |
25+
python -m build --sdist --wheel --outdir dist/ .
26+
- name: Publish distribution 📦 to PyPI
27+
if: startsWith(github.ref, 'refs/tags')
28+
uses: pypa/gh-action-pypi-publish@master
29+
with:
30+
password: ${{ secrets.PYPI_API_TOKEN }}

setup.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ def read(fname):
1212

1313
setup(
1414
name='netflix-spectator-py',
15-
version='0.1.17',
15+
version='0.1.18',
1616
description='Python library for reporting metrics to Atlas.',
1717
long_description=read('README.md'),
1818
long_description_content_type='text/markdown',

0 commit comments

Comments
 (0)