code-quality.yml 613 B

123456789101112131415161718192021222324
  1. name: Format and Lint Checks
  2. on:
  3. push:
  4. branches:
  5. - main
  6. paths:
  7. - '*.py'
  8. pull_request:
  9. types: [ assigned, opened, synchronize, reopened ]
  10. jobs:
  11. check:
  12. name: Format and Lint Checks
  13. runs-on: ubuntu-latest
  14. steps:
  15. - uses: actions/checkout@v3
  16. - uses: actions/setup-python@v4
  17. with:
  18. python-version: '3.10'
  19. cache: 'pip'
  20. - run: python -m pip install --upgrade pip
  21. - run: python -m pip install .[dev]
  22. - run: python -m flake8 .
  23. - run: python -m isort . --check-only --diff
  24. - run: python -m black . --check --diff