Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 60 additions & 0 deletions .github/workflows/pulls.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: Pulls

on: pull_request
jobs:
build:
runs-on: ubuntu-18.04
strategy:
fail-fast: false
matrix:
python-version: ['2.7', '3.4', '3.5', '3.6', '3.7', '3.8', '3.9']
include:
- tox_env: 'py27'
python-version: '2.7'
- tox_env: 'py34'
python-version: '3.4'
- tox_env: 'py35'
python-version: '3.5'
- tox_env: 'py36'
python-version: '3.6'
- tox_env: 'latest'
python-version: '3.7'
- tox_env: 'latest'
python-version: '3.8'
- tox_env: 'latest'
python-version: '3.9'
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
pip install pbr
pip install tox
tox -e ${{ matrix.tox_env }} --notest
- name: Run
run: |
tox -e ${{ matrix.tox_env }} -- --nocapture
lint:
runs-on: ubuntu-18.04
strategy:
fail-fast: false
matrix:
python-version: ['2.7', '3.4', '3.5', '3.6', '3.7', '3.8', '3.9']
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
pip install pbr
pip install --upgrade pip
pip install tox
tox -r -e pep8 --notest
- name: lint
run: |
tox -e pep8
39 changes: 39 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: release

on:
release:
types: [released, prereleased]

jobs:
build-and-publish-pypi:
permissions:
contents: read
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python_version: ["3.9"]
tox_env: ['latest']
steps:
- uses: actions/checkout@v3
- name: "Set up Python ${{ matrix.python_version }}"
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python_version }}
- name: Install dependencies
run: python -m pip install --upgrade pip
- name: Install building dependencies
run: pip install wheel tox
- name: Build venv
run: |
tox -e ${{ matrix.tox_env }} --notest
- name: Run
run: |
rm -rf dist || true
.tox/${{ matrix.tox_env }}/bin/python setup.py sdist bdist_wheel
- name: Publish a Python distribution to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
if: github.event_name == 'release'
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
39 changes: 0 additions & 39 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
requests==2.21.0;python_version<'3.6'
request;python_version>='3.6'
requests;python_version>='3.6'
6 changes: 3 additions & 3 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@ envlist = py34,py35,py36,py37,py38,py27,pep8
deps = -r{toxinidir}/test-requirements.txt
install_command = python -m pip install -c constraints.txt {opts} {packages}
commands =
nosetests
nosetests {posargs}

[testenv:latest]
deps = -r{toxinidir}/test-requirements.txt
basepython = python3.8
basepython = python3
install_command = python -m pip install {opts} {packages}
commands =
nosetests
nosetests {posargs}

[testenv:pep8]
deps = -r{toxinidir}/test-requirements.txt
Expand Down