Files
walkies/.claude/agents/go-dev.md
2026-03-05 15:59:33 -04:00

1.1 KiB

description, globs, alwaysApply
description globs alwaysApply
Standard Go development commands for this project **/*.go false

Go Development Commands

Testing

# Run all tests
go test ./...

# Run tests in a specific package
go test ./internal/checkin/...

# Run a single test by name
go test ./internal/checkin/... -run TestCheckOut

# Run tests with verbose output
go test -v ./...

# Run tests with race detector
go test -race ./...

Formatting and Linting

# Format all Go files
gofmt -w .

# Organize imports (group stdlib, external, internal)
goimports -w .

# Vet for common mistakes
go vet ./...

Code Generation

# Regenerate sqlc query code after editing internal/store/queries/*.sql
task sqlc

# Regenerate proto/gRPC code after editing .proto files
task generate

Building

# Compile all packages (catches errors without producing binaries)
go build ./...

# Tidy module dependencies after adding/removing imports
go mod tidy

After any code change

  1. gofmt -w .
  2. goimports -w . (if imports changed)
  3. go vet ./...
  4. go test ./...