Skip to content

feat: add comprehensive Go development support with agents, commands, and skills#83

Merged
affaan-m merged 2 commits intoaffaan-m:mainfrom
msyahidin:claude/add-golang-support-frw0Z
Jan 27, 2026
Merged

feat: add comprehensive Go development support with agents, commands, and skills#83
affaan-m merged 2 commits intoaffaan-m:mainfrom
msyahidin:claude/add-golang-support-frw0Z

Conversation

@msyahidin
Copy link
Copy Markdown

@msyahidin msyahidin commented Jan 26, 2026

Summary

This PR adds complete Go language support to the Claude Code configuration collection, including specialized agents for code review and build error resolution, TDD-focused commands, and comprehensive skill documentation for idiomatic Go patterns and testing practices.

Key Changes

New Agents

  • agents/go-reviewer.md: Expert Go code reviewer focusing on idiomatic patterns, concurrency safety, error handling, and security vulnerabilities (SQL injection, command injection, race conditions)
  • agents/go-build-resolver.md: Go build error specialist that diagnoses and fixes compilation errors, go vet issues, and linter warnings with minimal, surgical changes

New Commands

  • commands/go-review.md: Invokes go-reviewer agent for comprehensive code review with severity categorization (CRITICAL/HIGH/MEDIUM)
  • commands/go-test.md: Enforces TDD workflow with table-driven tests, coverage verification (80%+ target), and RED-GREEN-REFACTOR cycle
  • commands/go-build.md: Invokes go-build-resolver agent to incrementally fix build errors with verification after each change

New Skills

  • skills/golang-patterns/SKILL.md: Comprehensive guide covering:

    • Core Go principles (simplicity, zero values, interface design)
    • Error handling patterns (wrapping, custom types, errors.Is/As)
    • Concurrency patterns (worker pools, context, graceful shutdown, errgroup)
    • Package organization and struct design
    • Memory optimization and performance best practices
    • Go tooling integration and anti-patterns to avoid
  • skills/golang-testing/: Go testing patterns, TDD methodology, and benchmarking (referenced in commands)

Documentation Updates

  • Updated README.md to:
    • Add Go language badge
    • List new agents, commands, and skills in project structure
    • Update contribution ideas to note Go support is now included

Implementation Details

  • Agents use Opus model for complex analysis and comprehensive reviews
  • Diagnostic commands follow Go best practices (go build, go vet, staticcheck, golangci-lint)
  • Error patterns documented with 10+ common Go compilation errors and fixes
  • Security focus includes SQL injection, command injection, race conditions, and unsafe pointer usage
  • TDD emphasis with table-driven test patterns and coverage targets by code type
  • Idiomatic Go patterns follow official Go conventions and community best practices

Related Issues

Addresses the contribution idea for "Language-specific skills (Python, Go, Rust patterns)" by providing complete Go support.

Summary by CodeRabbit

  • New Features

    • Added three Go workflow commands: TDD testing, code review analysis, and incremental build remediation.
  • Documentation

    • Added comprehensive Go guides for code review, build error resolution, patterns, and testing best practices.
    • Updated README with a Go platform badge, navigation updates, and Go contribution notes.

✏️ Tip: You can customize this high-level summary in your review settings.

Add Go-specific agents, skills, and commands for idiomatic Go development:

Agents:
- go-reviewer: Go code review for concurrency, error handling, security
- go-build-resolver: Fix Go build errors with minimal changes

Skills:
- golang-patterns: Idiomatic Go patterns, best practices, conventions
- golang-testing: TDD, table-driven tests, benchmarks, fuzzing

Commands:
- /go-review: Invoke Go code reviewer
- /go-test: Go TDD workflow with coverage
- /go-build: Fix Go build/vet/lint errors

Also updates README.md to document the new Go support.
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Jan 26, 2026

📝 Walkthrough

Walkthrough

Adds comprehensive Go support: new README badge and navigation updates, two agent guides (go-reviewer, go-build-resolver), three command workflows (go-review, go-test, go-build), and two skills (golang-patterns, golang-testing).

Changes

Cohort / File(s) Summary
README & Navigation
README.md
Added Go badge; updated navigation, badges, and contributions to include Go coverage and new Go resources.
Agent Documentation
agents/go-reviewer.md, agents/go-build-resolver.md
New go-reviewer guide with review rules, diagnostics, examples, and approval criteria; new go-build-resolver with build/vet/static analysis workflow, common error patterns, module guidance, and a surgical iterative fix playbook.
Command Workflows
commands/go-review.md, commands/go-test.md, commands/go-build.md
New command docs: go-review (static/security/concurrency review workflow), go-test (TDD RED-GREEN-REFACTOR, table-driven tests, coverage targets), go-build (incremental build-error remediation with example fixes).
Skills / Patterns & Testing
skills/golang-patterns/SKILL.md, skills/golang-testing/SKILL.md
Added comprehensive Go patterns guide (idioms, concurrency, interfaces, performance, anti-patterns) and Go testing skill (TDD, table tests, benchmarks, fuzzing, CI integration).

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

🐰 New Go guides in a tidy stack,
Docs and tests — no rabbit lacks.
Reviewers hop, resolvers track,
Patterns, tests, and build rollback.
Cheers from a rabbit with a tiny snack!

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The pull request title accurately summarizes the main objective of the changeset, clearly identifying the addition of comprehensive Go development support through agents, commands, and skills.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


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 and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 6

🤖 Fix all issues with AI agents
In `@agents/go-build-resolver.md`:
- Around line 128-136: In agents/go-build-resolver.md there are multiple fenced
code blocks missing language labels (notably around the snippets shown near
lines 128-136 and also in the ranges 308-328 and 343-358); update each unlabeled
``` fence to use a language tag (use ```text for plain output/console blocks) so
markdownlint passes—search for triple-backtick blocks without a language and
replace them with ```text while preserving the block contents and spacing
(examples include the Before/After cycle block, numbered build/test steps, error
snippet showing "undefined: UserService", and the Build Status summary).

In `@agents/go-reviewer.md`:
- Around line 224-236: In the "## Review Output Format" section update the
opening fenced code block to include a language identifier (e.g., change the
triple backticks to triple backticks followed by "text") so the block is
rendered as a labeled code block; edit the code fence that wraps the SQL
Injection example (the block beginning with ```) to become ```text to satisfy
MD040 and improve markdown tooling compatibility while leaving the inner example
content and closing fence unchanged.

In `@commands/go-build.md`:
- Around line 46-145: The markdown example session fences are missing language
identifiers (causing MD040); update the triple-backtick fences that wrap the
example Go build session (the blocks that start with "User: /go-build" and the
final fence after "Build Status: ✅ SUCCESS") to include a language label (e.g.,
```text) so the session is properly rendered, and apply the same change to the
other identical fence pair referenced (lines 118-132) to ensure all example
session blocks use labeled code fences.

In `@commands/go-review.md`:
- Around line 71-128: The fenced code block showing the example conversation
(starting with "User: /go-review" and "Agent:" in the diff) lacks a
language/info string; update the opening triple-backtick fence to include a
language tag (e.g., ```text or ```md) so markdown linters and renderers
correctly highlight it and then close the block with the matching closing
triple-backticks; ensure you change the opening fence near the "User:
/go-review" example and keep the block contents unchanged.

In `@commands/go-test.md`:
- Around line 38-170: The top-level fenced example containing the TDD session
(the block that begins with the line "User: /go-test I need a function to
validate email addresses" and ends after "## TDD Complete!") is missing a
language label on the opening ``` fence; update the opening fence from ``` to
```text (or another appropriate language) so the block is labeled and MD040 is
avoided, leaving the rest of the fence content and closing ``` unchanged.

In `@skills/golang-patterns/SKILL.md`:
- Around line 367-385: The fenced code block showing the project tree in
skills/golang-patterns/SKILL.md is missing a language tag; change the opening
backticks from ``` to ```text (or another suitable tag like ```bash) so the
block is explicitly tagged and markdownlint MD040 is resolved.

Comment on lines +46 to +145
```
User: /go-build

Agent:
# Go Build Resolution

## Initial Diagnostics

```bash
$ go build ./...
internal/service/user.go:25:15: undefined: UserRepository
internal/handler/api.go:42:9: cannot use x (type string) as type int
internal/handler/api.go:58:2: missing return at end of function
```

Errors found: 3

## Fix 1: Undefined Identifier

File: internal/service/user.go:25
Error: undefined: UserRepository
Cause: Missing import

```go
// Added import
import "project/internal/repository"

// Changed
var repo UserRepository
// To
var repo repository.UserRepository
```

```bash
$ go build ./...
# 2 errors remaining
```

## Fix 2: Type Mismatch

File: internal/handler/api.go:42
Error: cannot use x (type string) as type int

```go
// Changed
count := params.Get("count")
// To
countStr := params.Get("count")
count, _ := strconv.Atoi(countStr)
```

```bash
$ go build ./...
# 1 error remaining
```

## Fix 3: Missing Return

File: internal/handler/api.go:58
Error: missing return at end of function

```go
func GetUser(id string) (*User, error) {
if id == "" {
return nil, ErrInvalidID
}
user := findUser(id)
// Added missing return
return user, nil
}
```

```bash
$ go build ./...
# Build successful!
```

## Final Verification

```bash
$ go vet ./...
# No issues

$ go test ./...
ok project/internal/service 0.015s
ok project/internal/handler 0.023s
```

## Summary

| Metric | Count |
|--------|-------|
| Build errors fixed | 3 |
| Vet warnings fixed | 0 |
| Files modified | 2 |
| Remaining issues | 0 |

Build Status: ✅ SUCCESS
```

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

Label the example session fences with a language.
This resolves MD040 and improves rendering in tooling.

🔧 Suggested fix
-```
+```text
 User: /go-build

 Agent:
 # Go Build Resolution
@@
 Build Status: ✅ SUCCESS
-```
+```

Also applies to: 118-132

🧰 Tools
🪛 markdownlint-cli2 (0.18.1)

71-71: Fenced code blocks should have a language specified

(MD040, fenced-code-language)


128-128: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

🤖 Prompt for AI Agents
In `@commands/go-build.md` around lines 46 - 145, The markdown example session
fences are missing language identifiers (causing MD040); update the
triple-backtick fences that wrap the example Go build session (the blocks that
start with "User: /go-build" and the final fence after "Build Status: ✅
SUCCESS") to include a language label (e.g., ```text) so the session is properly
rendered, and apply the same change to the other identical fence pair referenced
(lines 118-132) to ensure all example session blocks use labeled code fences.

@msyahidin msyahidin changed the title Add comprehensive Go development support with agents, commands, and skills feat: add comprehensive Go development support with agents, commands, and skills Jan 26, 2026
Add `text` language identifier to unlabeled fenced code blocks
to satisfy markdownlint MD040 rule across Go documentation files.
@affaan-m affaan-m merged commit 7fc5ef1 into affaan-m:main Jan 27, 2026
2 checks passed
moyueheng added a commit to moyueheng/everything-claude-code that referenced this pull request Jan 29, 2026
675db95 feat: unify commands and skills (v1.2.0)
ca584e2 fix: escape pipe in markdown table for markdownlint
a44a055 fix: resolve ESLint errors and update tests for project-name fallback
c9ef02b docs: add requirements section and hooks field warning
0c53ad8 Revert "docs: update shorthand to shortform terminology"
c3430bd docs: add Traditional Chinese translation
fbe2e56 docs: add simplified Chinese README
7c0bc25 feat: add comprehensive CI/CD pipeline
58a97c8 docs: update shorthand to shortform terminology
04ee208 docs: add plugin manifest validation notes
e3a1306 fix: remove duplicate hooks declaration from plugin.json
81003b1 feat: use project name as session filename fallback
8996303 fix: prevent command injection in Prettier hook (affaan-m#102)
8894e1b docs: update README with skill-create and instinct commands
9bc587a feat: add skill-create and continuous-learning-v2 commands
0ced59a Merge pull request affaan-m#91 from Hor1zonZzz/fix/readme-rules-limitation
2563d1e Merge pull request affaan-m#92 from jhsong-musinsa/fix/plugin-manifest-validation
5dc1edb Merge pull request affaan-m#93 from pangerlkr/patch-3
2aac2d9 Create PLUGIN_SCHEMA_NOTES.md
cdf987d fix: use explicit file paths for agents in plugin.json
384b255 docs: add note about rules limitation in plugin installation
accbb47 feat: add proper header banner to shortform guide
ff67b03 feat: add images and rename guides to the-shortform-guide.md and the-longform-guide.md
7fc5ef1 Merge pull request affaan-m#83 from msyahidin/claude/add-golang-support-frw0Z
779085e fix: add missing agents and hooks declarations to plugin.json
5e1835a Merge pull request affaan-m#81 from pangerlkr/patch-2
2abefe6 Merge pull request affaan-m#79 from pangerlkr/patch-1
4bca615 Merge pull request affaan-m#80 from lichengzhe/fix/stop-hook-shell-error
a1f47f1 Merge pull request affaan-m#85 from roeiba/add-license-file
01ad21b docs: add missing MIT LICENSE file
c6c32cd fix: add language labels to fenced code blocks for MD040 compliance
75e1e46 feat: add comprehensive Golang language support
2feac5a docs: add The Longform Guide to Everything Claude Code
a0b84f7 Fix: Move Stop hook inline code to separate script file
1564213 docs: add The Shorthand Guide to Everything Claude Code
56ff5d4 fix: use correct unscoped agent-browser package name (affaan-m#77)
5c63fa9 feat: v1.1.0 release - session ID tracking, async hooks, new skills
5670fcd Fix plugin manifest validation errors (affaan-m#75)
1c9fa0b Add hooks.md to documentation index (affaan-m#40)
2bfd2fb feat: add cloud infrastructure security skill (affaan-m#44)
fae9716 feat(agents): add database-reviewer agent with Supabase patterns (affaan-m#48)
a2087a8 fix: remove unnecessary .sh hooks (affaan-m#41)
b9b7831 fix: multiple community-reported issues
660e0d3 fix: security and documentation fixes
a7bc5f2 revert: remove hooks declaration - auto-loaded by convention
22ad036 fix: add hooks declaration to plugin.json for proper hook loading
5230892 fix: remove version fields from marketplace.json
970f8bf feat: cross-platform support with Node.js scripts
4ec7a6b fix: remove version field to enable automatic plugin updates
0d438dd style: side-by-side guide layout matching profile README
7f4f622 feat: add star history chart and minimal badge bar
c3f1594 fix: move session-end hooks from Stop to SessionEnd
19345df fix: remove duplicate hooks field from plugin.json
73bda1a fix: use ${CLAUDE_PLUGIN_ROOT} for hook script paths
ecfbbd3 fix: use relative path './' for plugin source instead of GitHub object
ee5affb fix: remove agents field temporarily to debug validation
d362ae6 fix: use string format for repository field in plugin.json
9e8006c fix: use GitHub source object in marketplace.json
5010f82 feat: package as Claude Code plugin with marketplace distribution
4491f15 Clarify README description of the repository
e6440d3 docs: restructure README to flow shorthand → longform guides together
fa0928a Enhance README with update section and resources
2d6fd70 feat: add strategic-compact hook and update hooks.json with all hooks
f96ef1e feat: add memory persistence hooks and context files
7d3ea0f feat: add strategic compact skill
6bf102d feat: add continuous learning skill with session examples
3c1e7d9 Clarify repository purpose and additional resources
62a80df Update README with image and guide link
6eefb41 Update README with guide reading reminder
d7cf890 Fix formatting in README.md for guide link
e57979c Update README with image and guide link
45959c3 Initial release: Complete Claude Code configuration collection
REVERT: 69c0b1a Add link to Agent Skills specification website (affaan-m#160)
REVERT: be229a5 Fix links in agent skills specification (affaan-m#159)
REVERT: f232228 Split agent-skills-spec into separate authoring and client integration guides (affaan-m#148)
REVERT: 0075614 Add doc-coauthoring skill and update example skills (affaan-m#134)
REVERT: ef74077 Move example skills into dedicated folder and create minimal top-level folder structure (affaan-m#129)
REVERT: 0f77e50 Update example skills and rename 'artifacts-builder' (affaan-m#112)
REVERT: e5c6015 Add 'frontend-design' example skill (affaan-m#98)
REVERT: c74d647 Clarify Claude Code installation in README.md (#20)
REVERT: 0877bae Updates to README.md (affaan-m#9)
REVERT: b118d29 Add Claude Claude instructions to the readme (#8)
REVERT: 4d1e3f3 Add Claude Code Marketplace (affaan-m#5)
REVERT: 9b61003 Small tweak to blog link (#7)
REVERT: 10e0fbe Add initial Agent Skills Spec (#2)
REVERT: ec84104 Add 3rd Party notices (affaan-m#4)
REVERT: 67ada86 Adding more details to README (affaan-m#3)
REVERT: 83291af Reorganize the example skills (affaan-m#1)
REVERT: 37292f3 init repo

git-subtree-dir: upstream/anthropics-skills
git-subtree-split: 675db95
charlesbmi pushed a commit to charlesbmi/everything-claude-code that referenced this pull request Jan 29, 2026
…rt-frw0Z

Excellent contribution adding comprehensive Go language support. Includes go-reviewer and go-build-resolver agents, TDD commands, and detailed Go patterns/testing skills.
@coderabbitai coderabbitai bot mentioned this pull request Mar 13, 2026
8 tasks
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