Skip to content

Commit 5d78b47

Browse files
committed
Use GitHub actions instead of Travis CI
1 parent 4b363a8 commit 5d78b47

File tree

13 files changed

+114
-76
lines changed

13 files changed

+114
-76
lines changed

.coveragerc

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,15 @@ source = src
55
[report]
66
exclude_lines =
77
pragma: no cover
8+
except ImportError:
9+
\# Python <
810
raise NotImplementedError
11+
raise TypeError\(f?"Unexpected
12+
assert False,
13+
\s+next\($
14+
if MYPY:
15+
if TYPE_CHECKING:
16+
^\s+\.\.\.$
17+
^\s+pass$
918
ignore_errors = True
10-
omit =
11-
docs/*
12-
tests/*
19+

.flake8

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
[flake8]
2-
ignore = E203,W503,E704
2+
ignore = E203,W503
33
exclude = .git,.mypy_cache,.pytest_cache,.tox,.venv,__pycache__,build,dist,docs
44
max-line-length = 88

.github/workflows/lint.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Code quality
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
build:
7+
runs-on: ubuntu-latest
8+
9+
steps:
10+
- uses: actions/checkout@v2
11+
12+
- name: Set up Python 3.9
13+
uses: actions/setup-python@v2
14+
with:
15+
python-version: 3.9
16+
17+
- name: Install dependencies
18+
run: |
19+
python -m pip install --upgrade pip
20+
pip install tox
21+
22+
- name: Run code quality tests with tox
23+
run: tox
24+
env:
25+
TOXENV: black,flake8,mypy,manifest

.github/workflows/publish.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Publish
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- uses: actions/checkout@v2
14+
15+
- name: Set up Python 3.9
16+
uses: actions/setup-python@v2
17+
with:
18+
python-version: 3.9
19+
20+
- name: Build wheel and source tarball
21+
run: |
22+
pip install wheel
23+
python setup.py sdist bdist_wheel
24+
25+
- name: Publish a Python distribution to PyPI
26+
uses: pypa/gh-action-pypi-publish@release/v1
27+
with:
28+
user: __token__
29+
password: ${{ secrets.PYPI_TOKEN }}

.github/workflows/test.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Tests
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
build:
7+
runs-on: ubuntu-latest
8+
9+
strategy:
10+
matrix:
11+
python: ['3.6', '3.7', '3.8', '3.9', '3.10', 'pypy3']
12+
13+
steps:
14+
- uses: actions/checkout@v2
15+
16+
- name: Set up Python ${{ matrix.python-version }}
17+
uses: actions/setup-python@v2
18+
with:
19+
python-version: ${{ matrix.python-version }}
20+
21+
- name: Install dependencies
22+
run: |
23+
python -m pip install --upgrade pip
24+
pip install tox tox-gh-actions
25+
26+
- name: Run unit tests with tox
27+
run: tox

mypy.ini renamed to .mypy.ini

File renamed without changes.

.pyup.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
branch: main

.travis.yml

Lines changed: 0 additions & 53 deletions
This file was deleted.

MANIFEST.in

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,8 @@ include .bumpversion.cfg
88
include .coveragerc
99
include .editorconfig
1010
include .flake8
11+
include .mypy.ini
1112

12-
include codecov.yml
13-
include mypy.ini
1413
include tox.ini
1514

1615
include poetry.lock

codecov.yml

Lines changed: 0 additions & 10 deletions
This file was deleted.

0 commit comments

Comments
 (0)