Skip to content

Commit b935852

Browse files
authored
chore: sync lint config and docs
1 parent 6b43eff commit b935852

5 files changed

Lines changed: 21 additions & 20 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ bin/
99
dist/
1010
# Stray example binaries (e.g. `go build` run inside examples/* leaving the binary at repo root)
1111
/basic
12+
/examples/basic/basic
1213
/examples/*/main
1314
examples/**/*.bin
1415

.golangci.yml

Lines changed: 17 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,23 @@ linters:
1414
- whitespace
1515
- bodyclose
1616
- noctx
17+
settings:
18+
errcheck:
19+
check-type-assertions: true
20+
check-blank: false
21+
gocritic:
22+
enabled-tags:
23+
- diagnostic
24+
- performance
25+
disabled-checks:
26+
- hugeParam
27+
- rangeValCopy
28+
- appendAssign
29+
# appendCombine hurts readability when each appended item is a
30+
# documented struct literal.
31+
- appendCombine
32+
staticcheck:
33+
checks: ["all", "-SA1019"]
1734
exclusions:
1835
presets:
1936
- comments
@@ -26,21 +43,6 @@ linters:
2643
- noctx
2744
- bodyclose
2845

29-
linters-settings:
30-
errcheck:
31-
check-type-assertions: true
32-
check-blank: false
33-
gocritic:
34-
enabled-tags:
35-
- diagnostic
36-
- performance
37-
disabled-checks:
38-
- hugeParam
39-
- rangeValCopy
40-
- appendAssign
41-
staticcheck:
42-
checks: ["all", "-SA1019"]
43-
4446
issues:
4547
max-issues-per-linter: 0
4648
max-same-issues: 0

CHANGELOG.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
3030
- `.github/workflows/ci.yml` — race tests + coverage upload + lint
3131
(golangci-lint v2) + multi-platform build matrix
3232
(linux/darwin/windows × amd64/arm64) + govulncheck.
33-
- `.github/dependabot.yml` — weekly `gomod` + `github-actions`
34-
updates.
3533
- `.github/PULL_REQUEST_TEMPLATE.md` — Summary / Changes / API impact
3634
/ Daemon compatibility / Testing / Checklist.
3735
- `.github/ISSUE_TEMPLATE/bug_report.yml` — structured bug report.

SECURITY.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,8 @@ We follow [coordinated vulnerability disclosure](https://en.wikipedia.org/wiki/C
4444

4545
## Security practices in this repo
4646

47-
- **Dependency monitoring:** automated via Dependabot (see
48-
`.github/dependabot.yml`).
47+
- **Dependency monitoring:** vulnerable dependencies are detected by
48+
`govulncheck`, which runs on every CI build (see "Vulnerability scanning").
4949
- **Static analysis:** `golangci-lint` / `ruff` / `mypy` enforced in CI.
5050
- **Vulnerability scanning:** `govulncheck` (Go) / `pip-audit` (Python) run
5151
on every CI build.

docs/architecture.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ resp, err := c.Chat(ctx, hawksdk.ChatRequest{Message: "list files"})
5757
// 📡 Streaming chat
5858
stream, err := c.ChatStream(ctx, hawksdk.ChatRequest{Message: "explain this code"})
5959
defer stream.Close()
60-
for stream.Next() { fmt.Print(stream.Event().Data) }
60+
for { ev, err := stream.Next(); if err != nil { break }; fmt.Print(ev.Data) }
6161

6262
// 📋 Sessions
6363
sessions, _ := c.Sessions(ctx, hawksdk.ListOptions{Limit: 10})

0 commit comments

Comments
 (0)