Minimize copy-pase in Github Actions file

This commit is contained in:
PerchunPak 2021-10-12 19:20:03 +03:00 committed by GitHub
parent ecee230c6f
commit 9261bec264
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -2,34 +2,17 @@ name: main
on:
push:
branches: [main]
tags:
branches: main
pull_request:
jobs:
main:
strategy:
matrix:
os: [ubuntu-latest]
python: [pypy-3.7, 3.6, 3.7, 3.8, 3.9, '3.10.0-alpha - 3.10.999']
toxenv: [py]
include:
# linux
- os: ubuntu-latest
python: pypy-3.7
toxenv: py
- os: ubuntu-latest
python: 3.6
toxenv: py
- os: ubuntu-latest
python: 3.7
toxenv: py
- os: ubuntu-latest
python: 3.8
toxenv: py
- os: ubuntu-latest
python: 3.9
toxenv: py
- os: ubuntu-latest
python: '3.10.0-alpha - 3.10.999'
toxenv: py
# windows
- os: windows-latest
python: 3.6
@ -50,5 +33,7 @@ jobs:
- uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python }}
- run: python -mpip install --upgrade setuptools pip tox virtualenv
- run: |
pip install --upgrade pip
pip install --upgrade setuptools pip tox virtualenv
- run: tox -e ${{ matrix.toxenv }}