Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate to GitHubAction for GolangCI Lint #1795

Merged
merged 2 commits into from
Jan 23, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions .github/workflows/golangci-lint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: golangci-lint
on: # yamllint disable-line rule:truthy
push:
branches:
- main
pull_request: # yamllint disable-line rule:empty-values

permissions:
contents: read
checks: write # Used to annotate code in the PR

jobs:
golangci:
name: lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5.2.0
with:
go-version: stable
- name: golangci-lint
uses: golangci/golangci-lint-action@971e284b6050e8a5849b72094c50ab08da042db8 # v6.1.1
with:
version: v1.62.2
args: --timeout=10m
16 changes: 8 additions & 8 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ require (
github.com/sirupsen/logrus v1.9.3
github.com/spf13/cobra v1.7.0
github.com/tektoncd/pipeline v0.65.0
github.com/tektoncd/plumbing v0.0.0-20221102182345-5dbcfda657d7
github.com/tektoncd/plumbing v0.0.0-20250116154805-bf07e665a460
github.com/tidwall/sjson v1.2.4
go.opencensus.io v0.24.0
go.uber.org/zap v1.27.0
golang.org/x/oauth2 v0.22.0
golang.org/x/sync v0.8.0
golang.org/x/sync v0.10.0
golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028
google.golang.org/grpc v1.67.0
google.golang.org/protobuf v1.34.2
Expand Down Expand Up @@ -73,7 +73,7 @@ require (
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/google/gnostic-models v0.6.8 // indirect
github.com/google/go-containerregistry v0.19.2 // indirect
github.com/google/go-containerregistry v0.20.2 // indirect
github.com/google/go-querystring v1.0.0 // indirect
github.com/google/gofuzz v1.2.0 // indirect
github.com/google/s2a-go v0.1.7 // indirect
Expand Down Expand Up @@ -121,13 +121,13 @@ require (
go.opentelemetry.io/otel/trace v1.28.0 // indirect
go.uber.org/automaxprocs v1.5.3 // indirect
go.uber.org/multierr v1.11.0 // indirect
golang.org/x/crypto v0.26.0 // indirect
golang.org/x/crypto v0.31.0 // indirect
golang.org/x/exp v0.0.0-20230515195305-f3d0a9c9a5cc // indirect
golang.org/x/mod v0.17.0 // indirect
golang.org/x/net v0.28.0 // indirect
golang.org/x/sys v0.24.0 // indirect
golang.org/x/term v0.23.0 // indirect
golang.org/x/text v0.17.0 // indirect
golang.org/x/net v0.33.0 // indirect
golang.org/x/sys v0.28.0 // indirect
golang.org/x/term v0.27.0 // indirect
golang.org/x/text v0.21.0 // indirect
golang.org/x/time v0.5.0 // indirect
golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d // indirect
gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect
Expand Down
430 changes: 16 additions & 414 deletions go.sum

Large diffs are not rendered by default.

1 change: 0 additions & 1 deletion test/presubmit-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ source $(dirname $0)/../vendor/github.com/tektoncd/plumbing/scripts/presubmit-te

function post_build_tests() {
return_code=0
golangci-lint run --deadline=5m || return_code=1
echo "Diffing against the documentation yaml"
${REPO_ROOT_DIR}/hack/update-docs.sh -d || return_code=1
return ${return_code}
Expand Down
7 changes: 7 additions & 0 deletions vendor/github.com/tektoncd/plumbing/.gitignore

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 7 additions & 2 deletions vendor/github.com/tektoncd/plumbing/OWNERS

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions vendor/github.com/tektoncd/plumbing/scripts/README.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 3 additions & 6 deletions vendor/github.com/tektoncd/plumbing/scripts/deploy-release.sh

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading