Skip to content

Commit 7bf4821

Browse files
authored
repo: updates to ci build (#24)
1 parent 4b760e1 commit 7bf4821

4 files changed

Lines changed: 45 additions & 64 deletions

File tree

.github/workflows/ci.yaml

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -8,16 +8,6 @@ on:
88
branches:
99
- 'main'
1010
jobs:
11-
run-copywrite:
12-
timeout-minutes: 5
13-
runs-on: ubuntu-24.04
14-
steps:
15-
- uses: actions/checkout@v6
16-
- uses: hashicorp/setup-copywrite@v1.1.3
17-
- name: verify copyright
18-
run: |
19-
copywrite --config .github/workflows/scripts/copywrite.hcl \
20-
headers --spdx "BSD-3-Clause" --plan
2111
run-tests:
2212
timeout-minutes: 5
2313
runs-on: ubuntu-24.04
@@ -34,4 +24,4 @@ jobs:
3424
just sysinfo
3525
- name: Run Go Test
3626
run: |
37-
just init tidy lint test
27+
just init tidy lint tests
Lines changed: 41 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -1,46 +1,44 @@
1-
run:
2-
timeout: 5m
1+
version: "2"
32
linters:
43
enable:
5-
- asasalint
6-
- asciicheck
7-
- bidichk
8-
- bodyclose
9-
- copyloopvar
10-
- dogsled
11-
- dupword
12-
- durationcheck
13-
- errcheck
14-
- errname
15-
- errorlint
16-
- exhaustive
17-
- gochecknoinits
18-
- gocritic
19-
- gofmt
20-
- gosimple
21-
- govet
22-
- ineffassign
23-
- makezero
24-
- misspell
25-
- musttag
26-
- nilnil
27-
- noctx
28-
- paralleltest
29-
- perfsprint
30-
- prealloc
31-
- predeclared
32-
- reassign
33-
- revive
34-
- rowserrcheck
35-
- staticcheck
36-
- sqlclosecheck
37-
- tagalign
38-
- tenv
39-
- unused
40-
- whitespace
4+
- asasalint
5+
- asciicheck
6+
- bidichk
7+
- bodyclose
8+
- copyloopvar
9+
- dogsled
10+
- dupword
11+
- durationcheck
12+
- errname
13+
- errorlint
14+
- exhaustive
15+
- gochecknoinits
16+
- gocritic
17+
- makezero
18+
- misspell
19+
- musttag
20+
- nilnil
21+
- noctx
22+
- perfsprint
23+
- prealloc
24+
- predeclared
25+
- reassign
26+
- revive
27+
- rowserrcheck
28+
- sqlclosecheck
29+
- tagalign
30+
- usetesting
31+
- whitespace
32+
settings:
33+
exhaustive:
34+
default-signifies-exhaustive: true
35+
exclusions:
36+
generated: lax
37+
presets:
38+
- comments
39+
formatters:
40+
enable:
41+
- gofmt
42+
exclusions:
43+
generated: lax
4144

42-
linters-settings:
43-
paralleltest:
44-
ignore-missing-subtests: true
45-
exhaustive:
46-
default-signifies-exhaustive: true

Justfile

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,16 +15,9 @@ tidy:
1515

1616
# run tests across source tree
1717
[group('build')]
18-
test:
18+
tests:
1919
go test -v -race -count=1 ./...
2020

21-
# ensure copywrite headers present on source files
22-
[group('lint')]
23-
copywrite:
24-
copywrite \
25-
--config {{scripts}}/copywrite.hcl headers \
26-
--spdx "BSD-3-Clause"
27-
2821
# apply go vet command on source tree
2922
[group('lint')]
3023
vet:
@@ -38,7 +31,7 @@ lint: vet
3831
# locally install build dependencies
3932
[group('build')]
4033
init:
41-
go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.62.2
34+
go install github.com/golangci/golangci-lint/v2/cmd/golangci-lint@v2.11.4
4235

4336
# show host system information
4437
[group('build')]

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module cattlecloud.net/go/stacks
22

3-
go 1.23
3+
go 1.26
44

55
require github.com/shoenig/test v1.12.2
66

0 commit comments

Comments
 (0)