name : Build + CodeCov + Pylint/Black

on:
  push:
    branches:
    - main
    - HW*
    - dev
  pull_request:
    branches:
    - main
jobs:
  build:
    runs-on: ubuntu-latest
    strategy:
      matrix:
        python-version: ["3.9", "3.10"]
    steps:
    - uses: actions/checkout@v3
    - name: Setup Python
      uses: actions/setup-python@master
      with:
        python-version: 3.7

    - name: Install dependencies
      run: |
        make develop
    - name: Build Library
      run: |
        make build
    - name: Install Gym Environment
      run: |
        make install
    - name: Check package
      run: |
        make check
    - name: Code Autoformat + Analysing the code with pylint
      run: |
        make lint
    - name: Generate Report
      run: |
        make coverage
    - name: Upload coverage reports to Codecov
      uses: codecov/codecov-action@v3


