lint.yml 996 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. name: Lint
  2. on:
  3. push:
  4. tags:
  5. - v*
  6. branches:
  7. - master
  8. pull_request:
  9. jobs:
  10. golangci:
  11. name: golangci-lint
  12. runs-on: ubuntu-latest
  13. steps:
  14. - uses: actions/checkout@v2
  15. - name: golangci-lint
  16. uses: golangci/golangci-lint-action@v2
  17. with:
  18. version: v1.29
  19. # Optional: golangci-lint command line arguments.
  20. # args: --issues-exit-code=0
  21. # Optional: show only new issues if it's a pull request. The default value is `false`.
  22. # only-new-issues: true
  23. # Optional: if set to true then the action will use pre-installed Go
  24. # skip-go-installation: true
  25. checklicenses:
  26. name: checklicenses
  27. runs-on: ubuntu-latest
  28. steps:
  29. - uses: actions/checkout@v2
  30. - name: check license headers
  31. run: |
  32. set -exu
  33. go get -u github.com/u-root/u-root/tools/checklicenses
  34. $(go env GOPATH)/bin/checklicenses -c .ci/checklicenses_config.json