2
0

pythonpackage.yml 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. name: Python package
  2. on: [push, pull_request]
  3. jobs:
  4. build:
  5. runs-on: ${{ matrix.os }}
  6. strategy:
  7. matrix:
  8. os: [ubuntu-latest, macos-latest, windows-latest]
  9. python-version: [3.5, 3.6, 3.7, 3.8, 3.9, pypy3]
  10. exclude:
  11. # sqlite3 exit handling seems to get in the way
  12. - os: macos-latest
  13. python-version: pypy3
  14. # doesn't support passing in bytestrings to os.scandir
  15. - os: windows-latest
  16. python-version: pypy3
  17. # path encoding
  18. - os: windows-latest
  19. python-version: 3.5
  20. # path encoding
  21. - os: macos-latest
  22. python-version: 3.5
  23. fail-fast: false
  24. steps:
  25. - uses: actions/checkout@v2
  26. - name: Set up Python ${{ matrix.python-version }}
  27. uses: actions/setup-python@v2
  28. with:
  29. python-version: ${{ matrix.python-version }}
  30. - name: Install dependencies
  31. run: |
  32. python -m pip install --upgrade pip
  33. pip install -U pip coverage codecov flake8 fastimport
  34. - name: Install mypy
  35. run: |
  36. pip install -U mypy
  37. if: "matrix.python-version != 'pypy3'"
  38. - name: Style checks
  39. run: |
  40. python -m flake8
  41. - name: Typing checks
  42. run: |
  43. python -m mypy dulwich
  44. if: "matrix.python-version != 'pypy3'"
  45. - name: Build
  46. run: |
  47. python setup.py build_ext -i
  48. - name: Coverage test suite run
  49. run: |
  50. python -m coverage run -p -m unittest dulwich.tests.test_suite
  51. - name: Upload coverage details
  52. run: |
  53. codecov