name: Run checks

on:
  push:
    branches:
      - main
    tags:
      - "[0-9]+.[0-9]+.[0-9]+"
      - "[0-9]+.[0-9]+.[0-9]+rc[0-9]+"

  pull_request:
    branches:
      - main

jobs:
  tox:
    runs-on: ubuntu-latest
    strategy:
      matrix:
        environment:
          - "py36"
          - "py37"
          - "py38"

        include:
          - environment: "py36"
            python: "3.6"
          - environment: "py37"
            python: "3.7"
          - environment: "py38"
            python: "3.8"

    container:
      image: python:${{ matrix.python }}

    steps:
      - uses: actions/checkout@master
      - name: Install tox
        run: |
          python -m pip install --upgrade pip
          python -m pip install tox
      - name: Run tox
        run: |
          tox -e ${{ matrix.environment }}

name: Run checks

on:
  push:
    branches:
      - main
    tags:
      - "[0-9]+.[0-9]+.[0-9]+"
      - "[0-9]+.[0-9]+.[0-9]+rc[0-9]+"

  pull_request:
    branches:
      - main

jobs:
  tox:
    runs-on: ubuntu-latest
    strategy:
      matrix:
        environment:
          - "py36"
          - "py37"
          - "py38"

        include:
          - environment: "py36"
            python: "3.6"
          - environment: "py37"
            python: "3.7"
          - environment: "py38"
            python: "3.8"

    container:
      image: python:${{ matrix.python }}

    steps:
      - uses: actions/checkout@v2
      - name: Install tox
        run: |
          python -m pip install --upgrade pip
          python -m pip install tox
      - name: Run tox
        run: |
          tox -e ${{ matrix.environment }}

Use v2 of checkout action
Use v2 of checkout action
