You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

49 lines
1.4 KiB

  1. name: Build CI
  2. on: [pull_request, push]
  3. jobs:
  4. test:
  5. runs-on: ubuntu-latest
  6. steps:
  7. - name: Dump GitHub context
  8. env:
  9. GITHUB_CONTEXT: ${{ toJson(github) }}
  10. run: echo "$GITHUB_CONTEXT"
  11. - name: Translate Repo Name For Build Tools filename_prefix
  12. id: repo-name
  13. run: echo ::set-output name=repo-name::Adafruit-PlatformDetect
  14. - name: Set up Python 3.6
  15. uses: actions/setup-python@v1
  16. with:
  17. python-version: 3.6
  18. - name: Versions
  19. run: |
  20. python3 --version
  21. - name: Checkout Current Repo
  22. uses: actions/checkout@v1
  23. with:
  24. submodules: true
  25. - name: Checkout tools repo
  26. uses: actions/checkout@v2
  27. with:
  28. repository: adafruit/actions-ci-circuitpython-libs
  29. path: actions-ci
  30. - name: Install dependencies
  31. # (e.g. - apt-get: gettext, etc; pip: circuitpython-build-tools, requirements.txt; etc.)
  32. run: |
  33. source actions-ci/install.sh
  34. - name: Pip install pylint, black, & Sphinx
  35. run: |
  36. pip install --force-reinstall pylint black==19.10b0 Sphinx sphinx-rtd-theme
  37. - name: Library version
  38. run: git describe --dirty --always --tags
  39. - name: Check formatting
  40. run: |
  41. black --check --target-version=py35 .
  42. - name: PyLint
  43. run: |
  44. pylint $( find . -path './adafruit*.py' )
  45. - name: Build docs
  46. working-directory: docs
  47. run: sphinx-build -E -W -b html . _build/html