Skip to content
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
4 changes: 2 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@ jobs:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
- uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5
with:
go-version-file: 'tools/go.mod'
go-version-file: 'go.mod'
cache: true
cache-dependency-path: tools/go.sum
cache-dependency-path: go.sum
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd # v3
with:
terraform_wrapper: false
Expand Down
2 changes: 2 additions & 0 deletions .golangci.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
version: "2"
linters:
enable:
- misspell
exclusions:
generated: lax
presets:
Expand Down
15 changes: 2 additions & 13 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -245,27 +245,16 @@ install: build ## Install built provider into the local terraform cache


.PHONY: tools
tools: $(GOBIN) tools-golangci-lint ## Install useful tools for linting, docs generation and development
@ cd tools && go install github.com/client9/misspell/cmd/misspell

.PHONY: tools-golangci-lint
tools-golangci-lint: ## Download golangci-lint locally if necessary.
tools: $(GOBIN) ## Download golangci-lint locally if necessary.
@[[ -f $(GOBIN)/golangci-lint ]] || curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(GOBIN) v2.2.1


.PHONY: misspell
misspell:
@ $(GOBIN)/misspell -error -source go ./internal/
@ $(GOBIN)/misspell -error -source text ./templates/


.PHONY: golangci-lint
golangci-lint:
@ $(GOBIN)/golangci-lint run --max-same-issues=0 $(GOLANGCIFLAGS) ./internal/...


.PHONY: lint
lint: setup misspell golangci-lint check-fmt check-docs ## Run lints to check the spelling and common go patterns
lint: setup golangci-lint check-fmt check-docs ## Run lints to check the spelling and common go patterns

.PHONY: fmt
fmt: ## Format code
Expand Down
3 changes: 3 additions & 0 deletions generated/kbapi/kibana.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
package kbapi

//go:generate make clean all
2 changes: 1 addition & 1 deletion internal/elasticsearch/security/api_key/schema.go
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,6 @@ func (r *Resource) requiresReplaceIfUpdateNotSupported() planmodifier.String {
resp.RequiresReplace = version != nil && version.LessThan(MinVersionWithUpdate)
},
"Requires replace if the server does not support update",
"Requries replace if the server does not support update",
"Requires replace if the server does not support update",
)
}
7 changes: 0 additions & 7 deletions tools/go.mod

This file was deleted.

2 changes: 0 additions & 2 deletions tools/go.sum

This file was deleted.

3 changes: 0 additions & 3 deletions tools/kbapi_gen.go

This file was deleted.

8 changes: 0 additions & 8 deletions tools/tools.go

This file was deleted.

Loading