gochecknoglobals: all 37 package-level tables consolidated into the gameData struct (game/tables.go), built by newGameData() and carried on RogueGame as g.data (set in NewGame and Restore). ObjectKind Glyph()/objectKindForGlyph are now switches; the table-reading subtype Stringer methods are gone; isMagic is a RogueGame method. goconst: repeated words named (potionName/scrollName/ringName/goldName in object.go, wandName/staffName in sticks.go, ripWall in tables.go). exhaustive, testpackage: disabled in .golangci.yml with sneak's approval (2026-07-07). Also reverts misspell's silent corruption of the "ther" scroll-name syllable (it had become "there", changing generated scroll names vs C). Remaining red: cyclop/gocognit/nestif until refactor step 7; mnd awaits a ruling. TODO.md rotated; MEMORY.md lint notes updated.
38 lines
1.0 KiB
YAML
38 lines
1.0 KiB
YAML
version: "2"
|
|
|
|
run:
|
|
timeout: 5m
|
|
modules-download-mode: readonly
|
|
|
|
linters:
|
|
default: all
|
|
disable:
|
|
# Genuinely incompatible with project patterns
|
|
- exhaustruct # Requires all struct fields
|
|
- depguard # Dependency allow/block lists
|
|
- godot # Requires comments to end with periods
|
|
- wsl # Deprecated, replaced by wsl_v5
|
|
- wrapcheck # Too verbose for internal packages
|
|
- varnamelen # Short names like db, id are idiomatic Go
|
|
# Repo-specific exceptions approved by sneak (2026-07-06)
|
|
- paralleltest # Requires t.Parallel() in every test
|
|
# Approved by sneak 2026-07-07
|
|
- testpackage # Tests use internal package game to reach unexported state
|
|
- exhaustive # C-faithful switches handle only the cases C handled
|
|
|
|
linters-settings:
|
|
lll:
|
|
line-length: 88
|
|
funlen:
|
|
lines: 80
|
|
statements: 50
|
|
cyclop:
|
|
max-complexity: 15
|
|
dupl:
|
|
threshold: 100
|
|
|
|
issues:
|
|
exclude-use-default: false
|
|
max-issues-per-linter: 0
|
|
max-same-issues: 0
|