-
Notifications
You must be signed in to change notification settings - Fork 12
38 lines (38 loc) · 1.09 KB
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
name: Package Release
on:
push:
tags: "*"
release:
types: [released]
jobs:
publish:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 100
persist-credentials: false
- name: Fetch git tags
run: git fetch origin 'refs/tags/*:refs/tags/*'
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: "3.9"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install setuptools setuptools_scm wheel twine
- name: Build and Install Wheel
run: |
python setup.py bdist_wheel
pip install dist/scooby*.whl
- name: Test Report Generation with No Dependencies
run: python -c "import scooby;scooby.Report();"
- name: Build and Publish to PyPI
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
run: |
python setup.py sdist
twine upload --skip-existing dist/scooby*