Skip to content

Commit

Permalink
Get rid of Travis, move to Github Actions
Browse files Browse the repository at this point in the history
  • Loading branch information
Johan Bloemberg committed Dec 8, 2020
1 parent 4bace81 commit 6b702aa
Show file tree
Hide file tree
Showing 3 changed files with 74 additions and 50 deletions.
59 changes: 59 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
name: Test

on: push

jobs:
test:
runs-on: ubuntu-latest

strategy:
max-parallel: 5
matrix:
python-version:
- 2.7
- 3.6
- 3.7
- 3.8
- 3.9

steps:
- uses: actions/checkout@v1

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install tox tox-gh-actions
- name: Test with tox
run: tox

release:
runs-on: ubuntu-latest

needs: test

steps:
- uses: actions/checkout@master

- name: Set up Python 3.9
uses: actions/setup-python@v1
with:
python-version: 3.9

- name: Install pypa/build
run: python -m pip install build --user

- name: Build a binary wheel and a source tarball
run: >-
python -m build --sdist --wheel --outdir dist/ .
- name: Publish distribution to PyPI
if: startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@master
with:
password: ${{ secrets.pypi_password }}
26 changes: 15 additions & 11 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on: [pull_request]
jobs:
test:
runs-on: ubuntu-latest

strategy:
max-parallel: 5
matrix:
Expand All @@ -16,14 +17,17 @@ jobs:
- 3.9

steps:
- uses: actions/checkout@v1
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install tox tox-gh-actions
- name: Test with tox
run: tox
- uses: actions/checkout@v1

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install tox tox-gh-actions
- name: Test with tox
run: tox
39 changes: 0 additions & 39 deletions .travis.yml

This file was deleted.

0 comments on commit 6b702aa

Please sign in to comment.