Skip to content

docs(readme): note govulncheck/golangci-lint install to GOPATH/bin - #711

Merged
kevincodex1 merged 3 commits into
Gitlawb:mainfrom
euxaristia:docs/readme-govulncheck-path
Jul 20, 2026
Merged

docs(readme): note govulncheck/golangci-lint install to GOPATH/bin#711
kevincodex1 merged 3 commits into
Gitlawb:mainfrom
euxaristia:docs/readme-govulncheck-path

Conversation

@euxaristia

@euxaristia euxaristia commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

Summary

The contributor setup in README.md tells readers to go install golangci-lint and govulncheck, but does not mention that the resulting binaries land in $GOPATH/bin (default ~/go/bin). If that directory is not already on PATH, the tools cannot be run directly, which silently breaks the documented lint/security workflow. This adds a short note and an export PATH snippet so the tooling actually resolves.

Changes

  • README.md (contributor/lint-tooling section): document that installed binaries go to $GOPATH/bin, and add a copy-paste export PATH="$PATH:$(go env GOPATH)/bin" snippet.

Test plan

  • make lint and govulncheck ./... resolve after adding $(go env GOPATH)/bin to PATH.
  • Visual check of the rendered README section.

Summary by CodeRabbit

  • Documentation
    • Updated installation instructions to clarify where Go-installed vulnerability scanning tools (e.g., govulncheck) are placed, including the default ~/go/bin when $GOBIN isn’t set.
    • Added instructions to ensure the Go bin directory is included in your PATH, with a shell snippet to set it if needed.

@coderabbitai

coderabbitai Bot commented Jul 17, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: a8be0674-7805-41fc-9789-ab4d03dc7dbf

📥 Commits

Reviewing files that changed from the base of the PR and between a523733 and 8671f7c.

📒 Files selected for processing (1)
  • README.md
🚧 Files skipped from review as they are similar to previous changes (1)
  • README.md

Walkthrough

README.md clarifies where go install places binaries based on GOBIN and GOPATH, including the default ~/go/bin, and shows how to add the resolved directory to PATH.

Changes

Go tool setup documentation

Layer / File(s) Summary
Document Go tool PATH setup
README.md
Explains GOBIN and GOPATH/bin resolution and adds a shell snippet that appends the effective binary directory to PATH when needed.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Possibly related PRs

  • Gitlawb/zero#635: Updates the README with related go install and tool PATH setup guidance.
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately reflects the README update about installing govulncheck and golangci-lint to the Go bin directory.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@README.md`:
- Around line 378-383: Update the README installation-path example to use Go’s
configured GOBIN when set, falling back to $(go env GOPATH)/bin, and make the
PATH update idempotent so rerunning the command does not append the same
directory repeatedly.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: f3aac742-d397-4f14-a525-e542ca6eae6b

📥 Commits

Reviewing files that changed from the base of the PR and between 9acb411 and fbf8020.

📒 Files selected for processing (1)
  • README.md

Comment thread README.md Outdated
The installed binaries land in $GOPATH/bin (default ~/go/bin), which must
be on PATH to run govulncheck directly. Document the export snippet so the
lint/security tooling from the contributor setup actually resolves.
@euxaristia
euxaristia force-pushed the docs/readme-govulncheck-path branch from fbf8020 to f992a3b Compare July 17, 2026 05:32
Vasanthdev2004
Vasanthdev2004 previously approved these changes Jul 17, 2026

@Vasanthdev2004 Vasanthdev2004 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Docs-only change to README.md: notes that go install places binaries in $GOPATH/bin and shows how to add it to PATH. Build and vet are clean, and the added snippet (export PATH="$PATH:$(go env GOPATH)/bin") is correct and portable. Tiny wording nit, not worth blocking on: the sentence singles out "to run govulncheck directly" when the same applies to golangci-lint installed just above — "to run them directly" would be slightly more accurate. Approving.

golangci-lint installs to the same $GOPATH/bin as govulncheck, so the
PATH note applies to both, not just the one named.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Vasanthdev2004
Vasanthdev2004 previously approved these changes Jul 18, 2026

@Vasanthdev2004 Vasanthdev2004 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re-approving. This is the wording fix I asked for last round: it now says "run them directly" instead of singling out govulncheck, which reads right since golangci-lint installs to the same GOPATH/bin. Docs-only, nothing else to flag.

go install writes to GOBIN when set, with GOPATH/bin as the fallback, and
rerunning the old snippet appended the same directory repeatedly.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@euxaristia

Copy link
Copy Markdown
Contributor Author

Pushed 8671f7c: the install-path snippet now honors GOBIN with a $(go env GOPATH)/bin fallback, and the PATH update is guarded so rerunning it doesn't append duplicates (verified idempotent).

@euxaristia

Copy link
Copy Markdown
Contributor Author

Ready for review.

Docs-only PATH/GOBIN note. CI is green; CodeRabbit approved. No open review threads.

@kevincodex1 kevincodex1 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@kevincodex1
kevincodex1 merged commit c0b6b9e into Gitlawb:main Jul 20, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants