Contributeur Go

VérifiéSûr

Aide à formater et vérifier les messages de commit Go selon les normes du projet. Facilite également l'utilisation de l'outil git-codereview pour interagir avec Gerrit lors des revues de code. Utile pour contribuer au projet Go et suivre son processus de contribution.

Spar Skills Guide Bot
DeveloppementIntermédiaire
7002/06/2026
Claude Code
#go#gerrit#git#contribution

Recommandé pour

Notre avis

Ce skill aide à suivre le processus de contribution au projet Go, notamment le formatage des messages de commit et l'interaction avec Gerrit.

Points forts

  • Guide précis pour respecter les conventions de formatage des commits Go.
  • Intègre l'outil git-codereview pour gérer les révisions Gerrit.
  • Fournit un script de validation des messages de commit.
  • Rappelle les règles de vote Gerrit et les trybots.

Limites

  • Nécessite que git-codereview soit installé et configuré.
  • Ne couvre pas les cas avancés de conflits de fusion.
  • Le script de validation n'est disponible qu'en local.
Quand l'utiliser

Utilisez ce skill lorsque vous préparez une contribution au projet Go et devez formater ou vérifier un message de commit selon les normes officielles.

Quand l'éviter

Ne l'utilisez pas pour des projets qui n'utilisent pas Gerrit ou pour des contributions ne respectant pas le workflow Go.

Analyse de sécurité

Sûr
Score qualité90/100

The skill uses git, git-codereview, and a bash script for commit message validation, all standard tools for Go contribution. No destructive or exfiltrating commands are present, and no obfuscated payloads.

Aucun point d'attention détecté

Exemples

Format a commit message for a Go change
I need to write a commit message for a change in the 'math' package that fixes an overflow issue. Help me format it properly according to Go conventions.
Check an existing commit message
Check this Go commit message for compliance: 'fix: resolve overflow in math package'
Send changes to Gerrit
I have made some changes to the Go source code. How do I use git-codereview to mail them for review?

name: go-contributor description: Helps with contributing to the Go project. Use when you need to format or check a commit message for Go standards or interact with Gerrit using the git-codereview tool. license: Apache-2.0 metadata: category: development tags: [go, gerrit, git, contribution] allowed-tools: [git, git-codereview, bash] compatibility: gemini-cli: ">=0.30.0"

Go Contributor Skill

This skill helps you follow the Go contribution process, specifically focusing on commit message formatting and interaction with Gerrit.

Workflows

1. Formatting a Commit Message

A good Go commit message follows a strict format:

  • First Line: Prefix with package (e.g., math: ). Summary should complete "This change modifies Go to _____." No leading capital, no trailing period.
  • Body: Detailed context, wrap at 72 columns, blank line after first line.
  • Issues: Use Fixes #12345 or Updates #12345. For x/ repositories, use Fixes golang/go#12345.

See references/commit_message_template.md for more details.

2. Checking a Commit Message

You can use the provided script to validate a commit message:

./scripts/check_commit_msg.sh <commit_msg_file>

3. Interacting with Gerrit

Use the git-codereview tool (often aliased to git).

  • git codereview change: Create or amend a single commit in your branch.
  • git codereview mail: Send your changes to Gerrit for review.
  • git codereview sync: Sync your local branch with the master.
  • git codereview submit: Submit an approved change (usually done by maintainers).

Additional Resources

  • Gerrit Review Voting:
    • +1: Looks good, but may need minor changes or reviewer is not an approver.
    • +2: Approved for merge (only by maintainers).
    • Hold +1: Do not submit yet.
  • Trybots: Triggered by maintainers to run full test suite. Failures must be fixed and re-uploaded.

Common Shortcuts

Add these to your .gitconfig:

[alias]
    change = codereview change
    gofmt = codereview gofmt
    mail = codereview mail
    pending = codereview pending
    submit = codereview submit
    sync = codereview sync
Skills similaires