golang-modernize Skill (samber): What It Does and How to Install It
Makes Claude find old patterns in Go code and replace them with newer language features, standard library packages and tooling, safest changes first.
- Installs
- 41.2K
- on skills.sh
- Stars
- 3.7K
- on GitHub
- Files
- 3
- besides SKILL.md
- Updated
- Nov 2026
- last repo commit
golang-modernize makes Claude read your go.mod, scan for old Go patterns and suggest their modern replacements. In inline mode it only suggests changes tied to the code you are working on and asks whether to raise others. In full-scan mode it fans out five sub-agents and applies a codebase-wide rewrite in an isolated worktree. It writes ignored suggestions to a .modernize file in the project root so it does not repeat them.
Good for
- Go teams on an old go.mod who want to upgrade to a recent Go version
- Developers hitting deprecation warnings in the standard library
- Claude Code and Codex users running a CI or tooling refresh
Install golang-modernize
Claude Code
- 1
Copy this prompt.
Install the golang-modernize skill in Claude Code. Run this command: /plugin marketplace add samber/cc /plugin install cc-skills-golang@samber Then check that it loaded and tell me how to use it.
- 2
Paste it into Claude Code. It shows the change and asks before running it.
The README says these skills are built as atomic, cross-referencing units, and that installing only a subset gives a partial and potentially inconsistent view of the guidelines. It recommends installing all the general-purpose skills together, which the plugin does. Its manifest lists no hooks or MCP servers, and the repo holds 46 skills. Use the skills CLI line only if you want just this one. Pick one route, not both.
From the project README. Source.
What's in the skill
When it loads
Modernize Golang code to use recent language features, standard library improvements, and idiomatic patterns. Use when reviewing Go code with old-style patterns, when encountering a deprecation warning, or when the user asks for modernization, a Go version upgrade (e.g. to Go 1.27), or a CI/tooling refresh. Not for structural refactors, extracting functions, or moving code between packages (→ See `samber/cc-skills-golang@golang-refactoring` skill).
Sections in SKILL.md
- Workflow
- .modernize file format
- Go Version Changelogs
- Using the modernize linter
- Version-specific modernizations
- Tooling modernization
- Deprecated Packages Migration
- Go 1.27+ version-bump risk checklist
- Migration Priority Guide
- High priority (safety and correctness)
- Medium priority (readability and maintainability)
- Lower priority (gradual improvement)
- Related Skills
Key facts
- Author
- samber
- Repository
- samber/cc-skills-golang
- License
- MIT
- Skill version
- 1.5.1
- Installs on skills.sh
- 41,198 (Nov 2, 2026)
- GitHub stars
- 3,749 (Nov 2, 2026)
- skills.sh audits
- Gen Agent Trust Hub pass, Socket pass, Snyk pass (Nov 2, 2026)
- Last repo commit
- Nov 1, 2026
What it includes
Suggests only modernizations for the code you are working on and asks first
It asks once, through the question tool, whether to suggest what it noticed. If you skip, it stops and does not raise modernization again that session.
Inline modeScans the whole codebase with 5 sub-agents, then rewrites in an isolated worktree
Agents cover deprecated packages, language features, standard library upgrades, testing patterns, and tooling and infra. The scan is read-only; the rewrite happens in a worktree.
Runs code ·
Full-scan modeNine steps: check go.mod, read .modernize, scan, run golangci-lint and go test
Also runs go mod tidy and the test suite before suggesting a dependency update.
Runs code ·
WorkflowRecords suggestions you declined, one line each with date, category and note
Written to the project root when you explicitly ignore a suggestion.
Write ·
.modernize fileA seven-row table of Go 1.21 to 1.27 release notes to cite when suggesting a change
Go Version ChangelogsRuns golangci-lint with the modernize linter (v2.6.0 or newer) if available
Using the modernize linterA 15-row table, such as math/rand to math/rand/v2 and runtime.SetFinalizer to AddCleanup
Deprecated Packages MigrationFlags GODEBUG settings and crypto/tls.Config.Rand that can now fail the build
Go 1.27+ version-bump risk checklist30 numbered changes in high, medium and lower priority, safety fixes first
Migration Priority GuideTwo guides: tooling modernization, and before/after examples for Go 1.21 to 1.27
Reference guides
From the official docs
Permissions
Medium risk
It can rewrite many Go files at once in a git worktree and run go, golangci-lint and git commands in your project. Review that worktree before you merge it.
What it can do
- Read your data
- Create and change things
- Delete things
- Read-only mode
Watch out for
It edits Go files and runs go and git commands
The frontmatter allows Edit, Write and Bash for go, golangci-lint and git. Work on a branch and read the diff before you commit.
It can rewrite many files in one pass
Full-scan mode applies a codebase-wide rewrite in an isolated worktree. Review that worktree before you merge it.
It writes a .modernize file and can browse the web
Declined suggestions go into .modernize in your project root. The frontmatter also allows WebFetch and WebSearch. Commit or delete the file as you prefer.
Security advisories
No published security advisories as of Nov 2, 2026.
Technical details
| Turning on read-only | No read-only setting is documented in SKILL.md. |
|---|---|
| Talks to | Your AI provider receives the Go code and command output Claude reads |
| Sign-in and keys | SKILL.md names no account or API key. |
| Scopes |
|
Questions
How do I install golang-modernize?
Use the install box above. The plugin route installs the whole Go skill set (46 skills in the repo), and the skills CLI route installs only this skill. Pick one so you do not get every skill twice. The README says these skills cross-reference each other and installing a subset gives a partial view.
Does golang-modernize work in the Claude app?
The README documents no Claude app install, so the Claude tab in the install box is our generic zip-upload route, not a documented one. The skill reads and edits Go files and runs go commands on your machine, so Claude Code or Codex is the better fit.
Does golang-modernize need an API key?
SKILL.md names no API key or account. It does need Go installed on your machine.
Is golang-modernize safe to run?
It edits your Go files and runs go, golangci-lint and git commands in your project, so work on a branch and read the diff before you commit. The skill bundles no scripts: its other files are reference guides and an evals/evals.json file.
Will golang-modernize rewrite my whole codebase?
Only when you ask. SKILL.md says it must never run a large refactor while you work on something else. An explicit /golang-modernize call or a CI run scans everything and applies the rewrite in an isolated worktree.
How is it different from golang-refactoring?
SKILL.md says golang-modernize is not for structural refactors, extracting functions or moving code between packages; those go to golang-refactoring. Modernize swaps old patterns and APIs for newer ones.
What if I disagree with a suggestion?
Say so. When you explicitly ignore a suggestion, the skill writes a one-line note to .modernize in the project root and will not raise it again.
Information
updated Nov 2, 2026
- Repository
- samber/cc-skills-golang
- Folder
skills/golang-modernize
Sources
Docs, issue trackers and discussions this page is built from.
Show all 7Hide
- cc-skills-golang · github.com
- cc-skills-golang README · github.com
- plugin.json · github.com
- skills CLI commands · github.com
- README.md#-how-to-use · github.com
- golang-modernize SKILL.md · github.com
- golang-modernize on skills.sh · skills.sh