Skip to content

Commit 1a4f650

Browse files
committed
lints, CI etc
1 parent 3473aca commit 1a4f650

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,10 +118,23 @@ cd tests/;
118118
GOROOT=/path/to/go-panikint /path/to/go-panikint/bin/go test -v .
119119
```
120120
121+
CI notes:
122+
- Pull requests run workflow linting (actionlint + zizmor), `go vet`, and type checking (`go test -run=^$`) in `tests/` using the built toolchain.
123+
- Pushes to `master` run the build + tests (both truncation disabled/enabled).
124+
121125
Note: the upstream Go distribution tests in `$GOROOT/test` intentionally rely on integer wrap-around.
122126
The go-panikint unit tests live in `$GOROOT/tests` (plural) and should run with overflow checks enabled.
123127
When running `cmd/internal/testdir` (for example via `src/all.bash`), we disable overflow instrumentation using `GOPANIKINT_DISABLE_OVERFLOW=1`.
124128
129+
### Pre-commit (gofmt)
130+
131+
If you use `pre-commit` or `prek`, this repo includes a minimal `.pre-commit-config.yaml` that runs `gofmt` on staged Go files. The hook skips `test/` and any `testdata/` paths because those fixtures are intentionally not gofmt'ed in the Go repo.
132+
133+
Example:
134+
```bash
135+
prek run --all-files
136+
```
137+
125138
### Examples
126139
127140
#### Example 1 (Signed Integer Overflow):

0 commit comments

Comments
 (0)