Skip to content

Commit

Permalink
Speed up linters locally (#1867)
Browse files Browse the repository at this point in the history
  • Loading branch information
pavelbrm authored Jun 23, 2023
1 parent b28963e commit b90fb3b
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 20 deletions.
16 changes: 9 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -186,11 +186,13 @@ format:

format-lint:
make format && make lint

lint:
docker run --rm -v "$$(pwd):/app" --workdir /app/libs golangci/golangci-lint:v1.49.0 golangci-lint run -v ./...
docker run --rm -v "$$(pwd):/app" --workdir /app/services golangci/golangci-lint:v1.49.0 golangci-lint run -v ./...
docker run --rm -v "$$(pwd):/app" --workdir /app/tools golangci/golangci-lint:v1.49.0 golangci-lint run -v ./...
docker run --rm -v "$$(pwd):/app" --workdir /app/cmd golangci/golangci-lint:v1.49.0 golangci-lint run -v ./...
docker run --rm -v "$$(pwd):/app" --workdir /app/main golangci/golangci-lint:v1.49.0 golangci-lint run -v ./...
docker run --rm -v "$$(pwd):/app" --workdir /app/serverless/email/webhook golangci/golangci-lint:v1.49.0 golangci-lint run -v ./...
docker run --rm -v "$$(pwd):/app" --workdir /app/serverless/email/unsubscribe golangci/golangci-lint:v1.49.0 golangci-lint run -v ./...
docker volume create batgo_lint_gomod
docker run --rm -v "$$(pwd):/app" -v batgo_lint_gomod:/go/pkg --workdir /app/main golangci/golangci-lint:v1.49.0 golangci-lint run -v ./...
docker run --rm -v "$$(pwd):/app" -v batgo_lint_gomod:/go/pkg --workdir /app/cmd golangci/golangci-lint:v1.49.0 golangci-lint run -v ./...
docker run --rm -v "$$(pwd):/app" -v batgo_lint_gomod:/go/pkg --workdir /app/libs golangci/golangci-lint:v1.49.0 golangci-lint run -v ./...
docker run --rm -v "$$(pwd):/app" -v batgo_lint_gomod:/go/pkg --workdir /app/services golangci/golangci-lint:v1.49.0 golangci-lint run -v ./...
docker run --rm -v "$$(pwd):/app" -v batgo_lint_gomod:/go/pkg --workdir /app/tools golangci/golangci-lint:v1.49.0 golangci-lint run -v ./...
docker run --rm -v "$$(pwd):/app" -v batgo_lint_gomod:/go/pkg --workdir /app/serverless/email/webhook golangci/golangci-lint:v1.49.0 golangci-lint run -v ./...
docker run --rm -v "$$(pwd):/app" -v batgo_lint_gomod:/go/pkg --workdir /app/serverless/email/unsubscribe golangci/golangci-lint:v1.49.0 golangci-lint run -v ./...
2 changes: 1 addition & 1 deletion serverless/email/status/go.mod
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module notification
module github.com/brave-intl/bat-go/serverless/email/status

go 1.18

Expand Down
12 changes: 6 additions & 6 deletions serverless/email/unsubscribe/go.mod
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
module github.com/brave-intl/bat-go/serverless/email/unsubscribe

go 1.18

replace gopkg.in/yaml.v2 => gopkg.in/yaml.v2 v2.2.8

require (
github.com/aws/aws-lambda-go v1.34.1
github.com/aws/aws-sdk-go-v2 v1.17.1
Expand Down Expand Up @@ -40,9 +46,3 @@ require (
golang.org/x/sys v0.1.0 // indirect
google.golang.org/protobuf v1.28.1 // indirect
)

replace gopkg.in/yaml.v2 => gopkg.in/yaml.v2 v2.2.8

module webhook

go 1.18
12 changes: 6 additions & 6 deletions serverless/email/webhook/go.mod
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
module github.com/brave-intl/bat-go/serverless/email/webhook

go 1.18

replace gopkg.in/yaml.v2 => gopkg.in/yaml.v2 v2.2.8

require (
github.com/asaskevich/govalidator v0.0.0-20210307081110-f21760c49a8d
github.com/aws/aws-lambda-go v1.34.1
Expand Down Expand Up @@ -46,9 +52,3 @@ require (
google.golang.org/protobuf v1.28.1 // indirect
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect
)

replace gopkg.in/yaml.v2 => gopkg.in/yaml.v2 v2.2.8

module webhook

go 1.18

0 comments on commit b90fb3b

Please sign in to comment.