Skip to content

Commit

Permalink
linters: use golangci-lint GitHub action instead of a manual setup (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
jmontesi authored Oct 25, 2023
1 parent 49a011b commit b6ef470
Showing 1 changed file with 8 additions and 10 deletions.
18 changes: 8 additions & 10 deletions .github/workflows/pre-main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,6 @@ jobs:
with:
token: ${{ secrets.GITHUB_TOKEN }}

# TODO: golangci-lint team recommends using a GitHub Action to perform golangci-lint responsibilities. However
# there does not appear to be a way to honor our existing .golangci.yml. For now, mimic developer behavior.
- name: Install golangci-lint
run: make install-lint

- name: Install checkmake
run: |
curl --location --output $CM_BIN --silent $CM_URL_LINUX
Expand All @@ -69,6 +64,12 @@ jobs:
- name: Install Shfmt
uses: mfinelli/setup-shfmt@v3

- name: Golangci-lint
uses: golangci/golangci-lint-action@v3
with:
version: v1.54
args: --timeout 10m0s

- name: Checkmake
run: checkmake --config=.checkmake Makefile

Expand All @@ -81,7 +82,7 @@ jobs:
- name: Shfmt
run: shfmt -d *.sh script

- name: markdownlint
- name: Markdownlint
uses: nosborn/[email protected]
with:
files: .
Expand All @@ -97,10 +98,7 @@ jobs:
with:
config_file: .yamllint.yml

- name: Golangci-lint
run: golangci-lint run --timeout 10m0s

- name: make vet
- name: Go vet
run: make vet
unit-tests:
name: Run Unit Tests
Expand Down

0 comments on commit b6ef470

Please sign in to comment.