linting.yml 828 B

12345678910111213141516171819202122232425262728293031
  1. name: Linting
  2. on: [push, pull_request]
  3. jobs:
  4. lint:
  5. runs-on: ubuntu-latest
  6. permissions:
  7. checks: write
  8. contents: read
  9. pull-requests: write
  10. steps:
  11. - uses: actions/checkout@v4
  12. - name: Setup Python
  13. uses: actions/setup-python@v5
  14. with:
  15. python-version: '3.13'
  16. - name: Install dependencies
  17. run: |
  18. python -m pip install --upgrade pip
  19. pip install -r requirements-dev.txt
  20. - name: Python lint
  21. run: ruff check --output-format=github .
  22. - name: Python include order
  23. run: ruff check --select I --diff .
  24. - name: Python coding style
  25. run: ruff format --check --diff .
  26. - name: YAML lint
  27. run: yamllint --format github custom_components/tuya_local/devices