diff options
-rw-r--r-- | .github/workflows/release.yml | 37 | ||||
-rw-r--r-- | .travis.yml | 36 |
2 files changed, 37 insertions, 36 deletions
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 000000000..046af6f7f --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,37 @@ +name: Release + +on: + release: + types: + - published + +env: + DEFAULT_PYTHON: 3.9 + +jobs: + release-pypi: + name: Upload release to PyPI + runs-on: ubuntu-latest + steps: + - name: Check out code from Github + uses: actions/checkout@v2.3.4 + - name: Set up Python ${{ env.DEFAULT_PYTHON }} + id: python + uses: actions/setup-python@v2.2.2 + with: + python-version: ${{ env.DEFAULT_PYTHON }} + - name: Install requirements + run: | + python -m pip install -U pip twine wheel + python -m pip install -U "setuptools>=56.0.0" + - name: Build distributions + run: | + python setup.py sdist bdist_wheel + - name: Upload to PyPI + if: github.event_name == 'release' && startsWith(github.ref, 'refs/tags') + env: + TWINE_REPOSITORY: pypi + TWINE_USERNAME: __token__ + TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }} + run: | + twine upload --verbose dist/* diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index fe596f331..000000000 --- a/.travis.yml +++ /dev/null @@ -1,36 +0,0 @@ -language: python -stages: - - tests-cpython -jobs: - include: - - stage: tests-cpython - python: 3.6 - env: TOXENV=py36 -before_install: - - python --version - - uname -a - - lsb_release -a -install: - - pip install -U setuptools - - pip install tox - - virtualenv --version - - pip --version - - tox --version -script: - - pip install . -after_failure: - - more .tox/log/* | cat - - more .tox/*/log/* | cat -notifications: - email: - on_success: always - on_failure: always -deploy: - provider: pypi - user: Claudiu.Popa - password: - secure: lAlz/mySOEOqIMp9vYb6WVvd4YP/XmnP1XmDJWAziit4+ydSB52H0wUprBZjMHenChtflANIKXggiaVO6sw6EqU8mxMEMz+6ixs9ZA0robYy9CgYdMrXSAYgr8NHbf3WPTiD65ajP5bpQ/v6i5YhVXhTgotORBmhnMyn5LA/OvbQGWZqHsdtdXZpsflXuzEDD9SL/MgrvfOEBINJzHuXyKDqwOzqjNL9VeUoUHbubBk/haJtbXHPvAQR9SOtS1hBeq9sVAQghdxQTs39XNPAnzukgEwW0UNmmuW6bQ6UWbxztHHQYgXBni5cfhGE7B5GO2L0Cneuiwz99HGyDvdOSNgxNahLcIlAWCWzp71T7KSRnPhAFMVbw7/65eb5VIJKyrO9rwZi5zCo4+c9Wi0er7+l1PVLcEw9O+ouEYs1+1iY7JFyP4cHAPGd6h0POG/IE3UJZ/5yhOSBR6sYwRbR4Qc2zPflnZrjSgBCpaJ37Y+FZwg7BzPvElGteTmqm3PsdqWWJshYs/l5QaRuzUOalPlxJHDrau9JPm3KAlosJde7cUD5zooiy08GHfd8fle2zAbGjgk9p7VAFf/2BFJj261h9eAmFHwIgBW7jje3eBCYUbBuzl+uzGGQNdfyoNzrbRcnuVWr/Is9PefVf0OmLDPNTgJy0gevsMZgfoCCuiQ= - on: - tags: true - condition: "$TOXENV = py36" - distributions: sdist bdist_wheel |