Skip to content

Commit

Permalink
Use a better maintained and more flexible license checker tool (#267)
Browse files Browse the repository at this point in the history
Signed-off-by: Ignasi Barrera <[email protected]>
  • Loading branch information
nacx authored Oct 10, 2024
1 parent af1e088 commit eb7840b
Show file tree
Hide file tree
Showing 5 changed files with 38 additions and 19 deletions.
35 changes: 35 additions & 0 deletions .licenserc.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# Copyright 2024 Tetrate
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

header:
license:
spdx-id: Apache-2.0
copyright-owner: Tetrate
paths-ignore:
- '**/go.mod'
- '**/go.sum'
- '**/*.md'
- '**/*.lock'
- '**/*.txt'
- '**/*.json'
- '**/*.crt'
- '**/*.csr'
- '**/*.srl'
- '**/*.key'
- '**/.gitignore'
- '**/kubeconfig'
- '**/bin/*'
- LICENSE
- CODEOWNERS
- 'config/**/*.go'
16 changes: 0 additions & 16 deletions .licenserignore

This file was deleted.

2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ lint: $(GOLANGCI_LINT_CONFIG) config/lint ## Lint checks for all Go code
.PHONY: format
format: go.mod ## Format all Go code
@echo "Formatting code"
@go run $(LICENSER) apply -r "Tetrate"
@@go run $(SWEYES) header fix
@go run $(GOSIMPORTS) -local $(GO_MODULE) -w .
@gofmt -w .

Expand Down
2 changes: 1 addition & 1 deletion e2e/istio/cluster/istiogw-config.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2023 Tetrate
# Copyright 2024 Tetrate
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion env.mk
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ NAME ?= authservice

GOLANGCI_LINT ?= github.com/golangci/golangci-lint/cmd/[email protected]
GOSIMPORTS ?= github.com/rinchsan/gosimports/cmd/[email protected]
LICENSER ?= github.com/liamawhite/licenser@v0.6.1-0.20210729145742-be6c77bf6a1f
SWEYES ?= github.com/apache/skywalking-eyes/cmd/license-eye@v0.6.0
KIND ?= sigs.k8s.io/[email protected]
ENVTEST ?= sigs.k8s.io/controller-runtime/tools/setup-envtest@latest

Expand Down

0 comments on commit eb7840b

Please sign in to comment.