Adopt library-quality standard: formatting, linting, coverage, and docs site - #2
Draft
AndroidPoet wants to merge 1 commit into
Draft
Adopt library-quality standard: formatting, linting, coverage, and docs site#2AndroidPoet wants to merge 1 commit into
AndroidPoet wants to merge 1 commit into
Conversation
Bring shipkit up to the four-pillar library standard: - Formatting: format the codebase with gofumpt; CI now enforces gofumpt cleanliness instead of plain gofmt. - Linting: add .golangci.yml (errcheck, govet, ineffassign, staticcheck, unused, gofumpt) and wire golangci-lint into CI. Fix the issues it found (dynamic-format Errorf, ineffectual assignment, capitalized error string). - Coverage: add `make cover` / `make cover-html` and a CI coverage step that produces an atomic coverage profile and func summary, uploaded as an artifact. - Docs: add a Next.js documentation site under website/ with shipkit-specific content (intro, getting started, command reference, configuration, CI & releases, launch readiness, agent output) and a Pages deploy workflow. Also expand the Makefile with fmt/fmt-check/lint/cover targets and ignore coverage artifacts.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Brings the repo up to our four-pillar library-quality standard. Each pillar is verifiable locally and in CI.
1. Formatting
gofumpt -l .is empty.2. Linting / static analysis
.golangci.yml(golangci-lint v2) enablingerrcheck,govet,ineffassign,staticcheck,unused, andgofumptas a formatter.lintjob.Errorf(now a sentinelerrors.New),launch.go,install.go.golangci-lint run ./...reports 0 issues.fmt.Fprint*-to-writer errcheck noise is intentionally excluded in config (standard, well-known exclusion for CLI output writers).3. Test coverage
make coverrunsgo test ./... -coverprofile=coverage.out -covermode=atomicplus a func summary;make cover-htmlproduces a browsable HTML report.coverage.outas an artifact.4. Docs site
website/with project-specific content: Introduction, Getting Started, Command Reference, Configuration, CI & Releases, Launch Readiness, and Agent Output..github/workflows/docs.yml).Verification
go build ./...— passgo vet ./...— passgo test ./...— passgofumpt -l .— cleangolangci-lint run ./...— 0 issuespnpm build(docs) — static export succeedsNo pillars skipped.