-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.mise.toml
74 lines (62 loc) · 1.95 KB
/
.mise.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
# Default versions of tools, to update these, set [tools.override]
[tools]
bun = "latest"
golang = "1.23.5"
"go:gotest.tools/gotestsum" = "v1.12.0"
"go:golang.org/x/tools/cmd/goimports" = "latest"
"go:mvdan.cc/sh/v3/cmd/shfmt" = "latest"
"go:github.com/thenativeweb/get-next-version" = "latest"
"go:sigs.k8s.io/mdtoc" = "latest"
"ubi:golangci/golangci-lint" = "1.63.4"
"ubi:goreleaser/goreleaser" = "2"
"ubi:orhun/git-cliff" = "2"
[tasks.build]
description = "Build a binary for the current platform/architecture"
run = "go build -trimpath -o ./bin/ -v ./cmd/..."
[tasks.changelog]
description = "Generate a changelog for the current version"
outputs = ["CHANGELOG.md"]
run = ["git-cliff --config .cliff.toml --output CHANGELOG.md"]
[tasks.fmt]
alias = "format"
description = "Format code"
run = [
"go mod tidy",
"gofmt -s -w .",
"goimports -w .",
"shfmt -w .",
"bun node_modules/.bin/prettier --write '**/*.{json,yaml,yml,md,jsonschema.json}'",
]
[tasks.lint]
description = "Run linters"
run = "golangci-lint run"
[tasks.next-version]
description = """Get the version number that would be released if a release was ran right now.
Pass --rc to get the next release candidate version.
"""
run = ["./.github/scripts/get-next-version.sh"]
[tasks.test]
description = "Run tests"
run = "gotestsum"
## <<Stencil::Block(custom)>>
[tasks.generate]
description = "Generate code and documentation"
run = [
"go generate ./...",
"mise run docgen",
"mise run schemagen",
"mise run fmt",
]
[tasks.docgen]
description = "Generate documentation based on Stencil template functions"
run = "go run ./tools/docgen/docgen.go"
[tasks.schemagen]
description = "Generate JSON schema files for stencil configuration files"
run = "go run ./tools/schemagen/schemagen.go"
[tasks.update-readme-toc]
description = "Update the TOC in the README"
run = ["mdtoc --inplace --max-depth=5 README.md"]
[settings]
# Conflicts with bun, and we don't use it anyways.
disable_tools = ["node"]
## <</Stencil::Block>>