Debian Codegraph @

script/lint

raw symbols SCIP
1 #!/bin/bash -ex
2
3 # Ensure the repository is clean after code generation.
4 ./script/generate
5 test -z "$(git status --porcelain)"
6
7 # Still clean after formatting.
8 ./script/fmt
9 test -z "$(git status --porcelain)"
10
11 # And it's still clean after asmfmt.
12 # Note: we want to confirm we agree with asmfmt without actually depending on it.
13 find . -name '*.s' | xargs asmfmt -w
14 test -z "$(git status --porcelain)"
15
16 # Run suite of golangci-lint checks.
17 # (Provide examples directory explicitly since it is skipped by default.)
18 golangci-lint run ./... ./examples/...
19
20 # Check asm declarations.
21 go vet -vettool=$(which asmvet) ./...
22
23 # Custom linters.
24 ./script/linter/pkgdoc