Skip to content

Commit

Permalink
Bye travis
Browse files Browse the repository at this point in the history
  • Loading branch information
sbidoul committed Dec 8, 2020
1 parent a079abe commit 1d2c053
Show file tree
Hide file tree
Showing 3 changed files with 64 additions and 44 deletions.
55 changes: 55 additions & 0 deletions .github/workflows/ci.yml
@@ -0,0 +1,55 @@
name: CI

on:
pull_request:
push:

jobs:
pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- uses: pre-commit/action@v2.0.0
tests:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["2.7", "3.5", "3.6", "3.7", "3.8", "3.9"]
steps:
- uses: "actions/checkout@v2"
with:
# some tests work on the git history so we need all of it!
fetch-depth: 0
- uses: "actions/setup-python@v2"
with:
python-version: "${{ matrix.python-version }}"
- name: "Install dependencies"
run: python -m pip install tox tox-gh-actions
- name: "Run tox targets for ${{ matrix.python-version }}"
run: python -m tox
- name: Coveralls
if: matrix.python-version != 2.7
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
python -m pip install coveralls
coveralls
deploy:
runs-on: ubuntu-latest
needs:
- pre-commit
- tests
if: startsWith(github.ref, 'refs/tags')
steps:
- uses: "actions/checkout@v2"
- uses: "actions/setup-python@v2"
- name: Install pypa/build
run: python -m pip install build
- name: Build a binary wheel and a source tarball
run: python -m build --sdist --wheel --outdir dist/
- name: Publish distribution 📦 to Test PyPI
uses: pypa/gh-action-pypi-publish@master
with:
user: __token__
password: ${{ secrets.pypi_token }}
44 changes: 0 additions & 44 deletions .travis.yml

This file was deleted.

9 changes: 9 additions & 0 deletions tox.ini
Expand Up @@ -13,6 +13,15 @@ envlist =
py39
check_readme

[gh-actions]
python =
2.7: py27
3.5: py35
3.6: py36
3.7: py37
3.8: py38, check_readme
3.9: py39

[testenv]
skip_missing_interpreters = True
usedevelop = True
Expand Down

0 comments on commit 1d2c053

Please sign in to comment.