From 2c0b7b5275aa21e944b46d2c0587c714029e2b43 Mon Sep 17 00:00:00 2001 From: Edoardo Rosa <6991986+notdodo@users.noreply.github.com> Date: Fri, 10 Nov 2023 19:15:58 +0100 Subject: [PATCH] enh: lint and build action (#3) --- .github/workflows/gobuild.yml | 17 +++++++++++++++++ .github/workflows/golanci-lint.yml | 28 ---------------------------- 2 files changed, 17 insertions(+), 28 deletions(-) delete mode 100644 .github/workflows/golanci-lint.yml diff --git a/.github/workflows/gobuild.yml b/.github/workflows/gobuild.yml index 698ecea..1b5d5a4 100644 --- a/.github/workflows/gobuild.yml +++ b/.github/workflows/gobuild.yml @@ -9,7 +9,24 @@ on: paths: - "**.go" +permissions: + contents: read + pull-requests: read + jobs: + lint: + name: lint + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-go@v4 + with: + go-version: "1.20" + - name: golangci-lint + uses: golangci/golangci-lint-action@v3 + with: + version: latest + build: strategy: matrix: diff --git a/.github/workflows/golanci-lint.yml b/.github/workflows/golanci-lint.yml deleted file mode 100644 index 4442693..0000000 --- a/.github/workflows/golanci-lint.yml +++ /dev/null @@ -1,28 +0,0 @@ -name: Go linters -on: - push: - branches: - - main - paths: - - "**.go" - pull_request: - paths: - - "**.go" - -permissions: - contents: read - pull-requests: read - -jobs: - lint: - name: lint - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-go@v4 - with: - go-version: "1.20" - - name: golangci-lint - uses: golangci/golangci-lint-action@v3 - with: - version: latest