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.

34 lines
714 B

  1. name: CI
  2. on:
  3. pull_request:
  4. paths:
  5. - '**.go'
  6. branches:
  7. - master
  8. push:
  9. paths:
  10. - '**.go'
  11. branches:
  12. - master
  13. tags-ignore:
  14. - '**'
  15. jobs:
  16. test:
  17. name: Run the tests
  18. runs-on: ubuntu-latest
  19. steps:
  20. - name: Checkout code
  21. uses: actions/checkout@v2
  22. - name: Setup Go
  23. uses: actions/setup-go@v2
  24. with:
  25. go-version: '~1.16.4'
  26. - name: Install libolm
  27. run: sudo apt-get -y install libolm3 libolm-dev
  28. - name: Install linters
  29. run: |
  30. go install honnef.co/go/tools/cmd/staticcheck@latest
  31. go install github.com/fzipp/gocyclo/cmd/gocyclo@latest
  32. - name: Lint and test
  33. run: sh ./hooks/pre-commit