Skip to content

Commit 8beb6bd

Browse files
authored
[ignore] check license in all code files header (#229)
Signed-off-by: Augustin Husson <augustin.husson@amadeus.com>
1 parent bbf086c commit 8beb6bd

File tree

130 files changed

+1686
-12
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

130 files changed

+1686
-12
lines changed

.github/workflows/checks.yaml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,3 +76,25 @@ jobs:
7676

7777
- name: Check Documentation
7878
run: make check-docs
79+
checklicense:
80+
name: "check license headers"
81+
runs-on: ubuntu-latest
82+
steps:
83+
- name: checkout
84+
uses: actions/checkout@v6
85+
- name: Import environment variables from file
86+
run: cat ".github/env" >> $GITHUB_ENV
87+
88+
- uses: actions/setup-go@v6
89+
with:
90+
go-version: "${{ env.golang-version }}"
91+
check-latest: true
92+
cache: true
93+
94+
- name: Set up Go
95+
uses: actions/setup-go@v6
96+
with:
97+
go-version: "${{ env.golang-version }}"
98+
check-latest: true
99+
- name: check license headers
100+
run: make checklicense

.gitignore

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,4 +153,7 @@ $RECYCLE.BIN/
153153
built/
154154

155155
# tmp folder
156-
tmp/
156+
tmp/
157+
158+
# IDE specific files
159+
.idea/

Makefile

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,16 @@ check-docs: $(MDOX_BINARY)
9999
@echo ">> checking formatting and local/remote links"
100100
$(MDOX_BINARY) fmt --soft-wraps --check -l --links.validate.config-file=$(MDOX_VALIDATE_CONFIG) $(MD_FILES_TO_FORMAT)
101101

102+
.PHONY: checklicense
103+
checklicense:
104+
@echo ">> checking license"
105+
$(GOCMD) run ./ci-scripts/check-license --check
106+
107+
.PHONY: fixlicense
108+
fixlicense:
109+
@echo ">> adding license header where it's missing"
110+
$(GOCMD) run ./ci-scripts/check-license --fix
111+
102112
.PHONY: tidy
103113
tidy:
104114
go mod tidy -v
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
// Copyright The Perses Authors
2+
// Licensed under the Apache License, Version 2.0 (the \"License\");
3+
// you may not use this file except in compliance with the License.
4+
// You may obtain a copy of the License at
5+
//
6+
// http://www.apache.org/licenses/LICENSE-2.0
7+
//
8+
// Unless required by applicable law or agreed to in writing, software
9+
// distributed under the License is distributed on an \"AS IS\" BASIS,
10+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11+
// See the License for the specific language governing permissions and
12+
// limitations under the License.
13+
14+
package main
15+
16+
import (
17+
"flag"
18+
19+
"github.com/perses/perses/scripts/pkg/license"
20+
)
21+
22+
func main() {
23+
l := license.DefaultLicense()
24+
l.RegisterFlags()
25+
flag.Parse()
26+
l.Execute()
27+
}

go.mod

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ module github.com/perses/community-mixins
33
go 1.25.5
44

55
require (
6-
github.com/perses/perses v0.53.0-rc.0
6+
github.com/perses/perses v0.53.0-rc.0.0.20260113112038-1e65a7475ba9
77
github.com/perses/perses-operator v0.2.0
88
github.com/perses/plugins/gaugechart v0.11.1
99
github.com/perses/plugins/markdown v0.10.1
@@ -54,10 +54,10 @@ require (
5454
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
5555
github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f // indirect
5656
github.com/nexucis/lamenv v0.5.2 // indirect
57-
github.com/perses/common v0.28.1 // indirect
57+
github.com/perses/common v0.29.1 // indirect
5858
github.com/prometheus/client_golang v1.23.2 // indirect
5959
github.com/prometheus/client_model v0.6.2 // indirect
60-
github.com/prometheus/common v0.67.4 // indirect
60+
github.com/prometheus/common v0.67.5 // indirect
6161
github.com/prometheus/procfs v0.17.0 // indirect
6262
github.com/shopspring/decimal v1.4.0 // indirect
6363
github.com/sirupsen/logrus v1.9.3 // indirect

go.sum

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -146,10 +146,10 @@ github.com/onsi/ginkgo/v2 v2.27.2 h1:LzwLj0b89qtIy6SSASkzlNvX6WktqurSHwkk2ipF/Ns
146146
github.com/onsi/ginkgo/v2 v2.27.2/go.mod h1:ArE1D/XhNXBXCBkKOLkbsb2c81dQHCRcF5zwn/ykDRo=
147147
github.com/onsi/gomega v1.38.2 h1:eZCjf2xjZAqe+LeWvKb5weQ+NcPwX84kqJ0cZNxok2A=
148148
github.com/onsi/gomega v1.38.2/go.mod h1:W2MJcYxRGV63b418Ai34Ud0hEdTVXq9NW9+Sx6uXf3k=
149-
github.com/perses/common v0.28.1 h1:GNqv6eM5QL7d4RQvUnfLh0Zfkoxr/+fOb0Fwm8zIkLY=
150-
github.com/perses/common v0.28.1/go.mod h1:4dtPoryEAcBacDMwYWvlVjctvut8VbsiOjDzJArGDPg=
151-
github.com/perses/perses v0.53.0-rc.0 h1:f3V1j6EqnKyXUY0mNt4Zp/T6+5U/5SjtCzLHxj9sJDQ=
152-
github.com/perses/perses v0.53.0-rc.0/go.mod h1:q+gB4M2yT//cO6GlCjhOTJLDoSrqtkMLul72Z0WOueI=
149+
github.com/perses/common v0.29.1 h1:Pq+1Et9sW+2S2ZQ1W4uLktx8mNzWwCsuUMb1L20+wMU=
150+
github.com/perses/common v0.29.1/go.mod h1:pvg9bGOBqE8b9w84sgedPaixGuyeYRn1zq3eGZWRqs0=
151+
github.com/perses/perses v0.53.0-rc.0.0.20260113112038-1e65a7475ba9 h1:jxl/UiS/Bd8YB58+w2k66G9KnIzHlLw/yrIEm6EhNvA=
152+
github.com/perses/perses v0.53.0-rc.0.0.20260113112038-1e65a7475ba9/go.mod h1:q3MmvXG6DVYfZ9VFQsjQdwnqLSyA9qYQ/xkLI52OIgI=
153153
github.com/perses/perses-operator v0.2.0 h1:gIhKUWca8ncaxyvOk2USaGfQ32eNcXzjDN97UlQAP0M=
154154
github.com/perses/perses-operator v0.2.0/go.mod h1:91gFy0XicXrWSYSr4ChkMp16GSOkeXjKdkXlfEECw5g=
155155
github.com/perses/plugins/gaugechart v0.11.1 h1:RrpcMl6E8E3Iv0Czm5iItqaehjTpDV9dXQ4lBLh0xLU=
@@ -179,8 +179,8 @@ github.com/prometheus/client_golang/exp v0.0.0-20251212205219-7ba246a648ca h1:BO
179179
github.com/prometheus/client_golang/exp v0.0.0-20251212205219-7ba246a648ca/go.mod h1:gndBHh3ZdjBozGcGrjUYjN3UJLRS3l2drALtu4lUt+k=
180180
github.com/prometheus/client_model v0.6.2 h1:oBsgwpGs7iVziMvrGhE53c/GrLUsZdHnqNwqPLxwZyk=
181181
github.com/prometheus/client_model v0.6.2/go.mod h1:y3m2F6Gdpfy6Ut/GBsUqTWZqCUvMVzSfMLjcu6wAwpE=
182-
github.com/prometheus/common v0.67.4 h1:yR3NqWO1/UyO1w2PhUvXlGQs/PtFmoveVO0KZ4+Lvsc=
183-
github.com/prometheus/common v0.67.4/go.mod h1:gP0fq6YjjNCLssJCQp0yk4M8W6ikLURwkdd/YKtTbyI=
182+
github.com/prometheus/common v0.67.5 h1:pIgK94WWlQt1WLwAC5j2ynLaBRDiinoAb86HZHTUGI4=
183+
github.com/prometheus/common v0.67.5/go.mod h1:SjE/0MzDEEAyrdr5Gqc6G+sXI67maCxzaT3A2+HqjUw=
184184
github.com/prometheus/otlptranslator v1.0.0 h1:s0LJW/iN9dkIH+EnhiD3BlkkP5QVIUVEoIwkU+A6qos=
185185
github.com/prometheus/otlptranslator v1.0.0/go.mod h1:vRYWnXvI6aWGpsdY/mOT/cbeVRBlPWtBNDb7kGR3uKM=
186186
github.com/prometheus/procfs v0.17.0 h1:FuLQ+05u4ZI+SS/w9+BWEM2TXiHKsUQ9TADiRH7DuK0=
@@ -242,8 +242,8 @@ golang.org/x/crypto v0.46.0 h1:cKRW/pmt1pKAfetfu+RCEvjvZkA9RimPbh7bhFjGVBU=
242242
golang.org/x/crypto v0.46.0/go.mod h1:Evb/oLKmMraqjZ2iQTwDwvCtJkczlDuTmdJXoZVzqU0=
243243
golang.org/x/exp v0.0.0-20251219203646-944ab1f22d93 h1:fQsdNF2N+/YewlRZiricy4P1iimyPKZ/xwniHj8Q2a0=
244244
golang.org/x/exp v0.0.0-20251219203646-944ab1f22d93/go.mod h1:EPRbTFwzwjXj9NpYyyrvenVh9Y+GFeEvMNh7Xuz7xgU=
245-
golang.org/x/mod v0.31.0 h1:HaW9xtz0+kOcWKwli0ZXy79Ix+UW/vOfmWI5QVd2tgI=
246-
golang.org/x/mod v0.31.0/go.mod h1:43JraMp9cGx1Rx3AqioxrbrhNsLl2l/iNAvuBkrezpg=
245+
golang.org/x/mod v0.32.0 h1:9F4d3PHLljb6x//jOyokMv3eX+YDeepZSEo3mFJy93c=
246+
golang.org/x/mod v0.32.0/go.mod h1:SgipZ/3h2Ci89DlEtEXWUk/HteuRin+HHhN+WbNhguU=
247247
golang.org/x/net v0.48.0 h1:zyQRTTrjc33Lhh0fBgT/H3oZq9WuvRR5gPC70xpDiQU=
248248
golang.org/x/net v0.48.0/go.mod h1:+ndRgGjkh8FGtu1w1FGbEC31if4VrNVMuKTgcAAnQRY=
249249
golang.org/x/oauth2 v0.34.0 h1:hqK/t4AKgbqWkdkcAeI8XLmbK+4m4G5YeQRrmiotGlw=

main.go

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,16 @@
1+
// Copyright The Perses Authors
2+
// Licensed under the Apache License, Version 2.0 (the \"License\");
3+
// you may not use this file except in compliance with the License.
4+
// You may obtain a copy of the License at
5+
//
6+
// http://www.apache.org/licenses/LICENSE-2.0
7+
//
8+
// Unless required by applicable law or agreed to in writing, software
9+
// distributed under the License is distributed on an \"AS IS\" BASIS,
10+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11+
// See the License for the specific language governing permissions and
12+
// limitations under the License.
13+
114
package main
215

316
import (

pkg/dashboards/alertmanager/alertmanager_overview.go

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,16 @@
1+
// Copyright The Perses Authors
2+
// Licensed under the Apache License, Version 2.0 (the \"License\");
3+
// you may not use this file except in compliance with the License.
4+
// You may obtain a copy of the License at
5+
//
6+
// http://www.apache.org/licenses/LICENSE-2.0
7+
//
8+
// Unless required by applicable law or agreed to in writing, software
9+
// distributed under the License is distributed on an \"AS IS\" BASIS,
10+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11+
// See the License for the specific language governing permissions and
12+
// limitations under the License.
13+
114
package alertmanager
215

316
import (

pkg/dashboards/blackbox/blackbox.go

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,16 @@
1+
// Copyright The Perses Authors
2+
// Licensed under the Apache License, Version 2.0 (the \"License\");
3+
// you may not use this file except in compliance with the License.
4+
// You may obtain a copy of the License at
5+
//
6+
// http://www.apache.org/licenses/LICENSE-2.0
7+
//
8+
// Unless required by applicable law or agreed to in writing, software
9+
// distributed under the License is distributed on an \"AS IS\" BASIS,
10+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11+
// See the License for the specific language governing permissions and
12+
// limitations under the License.
13+
114
package blackbox
215

316
import (

pkg/dashboards/dashboard_writer.go

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,16 @@
1+
// Copyright The Perses Authors
2+
// Licensed under the Apache License, Version 2.0 (the \"License\");
3+
// you may not use this file except in compliance with the License.
4+
// You may obtain a copy of the License at
5+
//
6+
// http://www.apache.org/licenses/LICENSE-2.0
7+
//
8+
// Unless required by applicable law or agreed to in writing, software
9+
// distributed under the License is distributed on an \"AS IS\" BASIS,
10+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11+
// See the License for the specific language governing permissions and
12+
// limitations under the License.
13+
114
package dashboards
215

316
import (

0 commit comments

Comments
 (0)