Skip to content

Update pythonapp.yml #35

Update pythonapp.yml

Update pythonapp.yml #35

Workflow file for this run

name: build
on: [push]
jobs:
build:
strategy:
matrix:
python: [ '3.6', '3.7', '3.8', '3.9' ]
os: [ 'windows-latest', 'ubuntu-latest' ]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}
- run: python -m pip install --upgrade pip
- run: pip install flake8 coverage
- run: flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
- run: flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- run: coverage run -m unittest discover tests
- run: coverage xml
- if: matrix.os == 'ubuntu-latest' && matrix.python == '3.9'
uses: sonarsource/sonarcloud-github-action@master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
SONAR_SCANNER_OPTS: -Dsonar.sources=. -Dsonar.tests=tests -Dsonar.exclusions=tests/** -Dsonar.python.coverage.reportPaths=coverage.xml -Dsonar.sourceEncoding=UTF-8 -Dsonar.organization=albertus82-github -Dsonar.projectKey=it.albertus:jar-classes-version-detector