1# SPDX-FileCopyrightText: Amolith <amolith@secluded.site>
2#
3# SPDX-License-Identifier: CC0-1.0
4
5default: fmt lint staticcheck test vuln reuse
6
7fmt:
8 # Formatting all Go source code
9 go install mvdan.cc/gofumpt@latest
10 gofumpt -l -w .
11
12lint:
13 # Linting Go source code
14 golangci-lint run
15
16staticcheck:
17 # Performing static analysis
18 go install honnef.co/go/tools/cmd/staticcheck@latest
19 staticcheck ./...
20
21test:
22 # Running tests
23 go test -v ./...
24
25vuln:
26 # Checking for vulnerabilities
27 go install golang.org/x/vuln/cmd/govulncheck@latest
28 govulncheck ./...
29
30reuse:
31 # Linting licenses and copyright headers
32 reuse lint
33
34clean:
35 # Cleaning up
36 rm -rf willow out/
37
38clean-all:
39 # Removing build artifacts, willow.sqlite, config.toml, and data/ directory
40
41 rm -rf willow out willow.sqlite config.toml data