code_style_check.yaml 695 B

1234567891011121314151617181920212223242526272829
  1. name: Code style check
  2. on: [pull_request]
  3. jobs:
  4. build:
  5. strategy:
  6. matrix:
  7. otp:
  8. - 24.2.1-1
  9. elixir:
  10. - 1.13.3
  11. os:
  12. - ubuntu20.04
  13. runs-on: ubuntu-20.04
  14. container: "ghcr.io/emqx/emqx-builder/5.0-8:${{ matrix.elixir}}-${{ matrix.otp }}-${{ matrix.os }}"
  15. steps:
  16. - uses: actions/checkout@v2
  17. with:
  18. fetch-depth: 1000
  19. - name: Run elvis check
  20. run: |
  21. ./scripts/elvis-check.sh $GITHUB_BASE_REF
  22. - name: Check line-break at EOF
  23. run: |
  24. ./scripts/check-nl-at-eof.sh
  25. - name: Check Elixir code formatting
  26. run: |
  27. mix format --check-formatted