commit

Generate Conventional Commits messages and push to origin with branch safety rules.

Updated Aug 27, 2026
One-click install
npx skills add https://github.com/thisguymartin/ai-native-dev --skill commit-thisguymartin
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: commit
Source: https://github.com/thisguymartin/ai-native-dev/tree/main/.gemini/skills/commit
Command: npx skills add https://github.com/thisguymartin/ai-native-dev --skill commit-thisguymartin

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Prevents accidental commits to protected branches, enforces consistent conventional commit messages, and handles linked worktree contexts so version control operations are safe and auditable.

Core Features & Use Cases

  • Worktree Detection: Automatically detects linked worktrees and avoids creating or switching branches when operating inside a worktree.
  • Branch Safety & Creation: Stops commits on main/master, prompts for context, and creates context-named feature/fix/refactor branches when required.
  • Semantic Commits & Push: Generates Conventional Commits-formatted messages, stages changes, commits, and pushes to origin while reporting push status and errors.
  • Use Case: Safely prepare and push a bug fix from a developer laptop or CI runner without accidentally committing directly to main.

Quick Start

Create and push a semantic commit for all current changes, creating a context-named branch if I am on main and then report the Git summary.

Frequently Asked Questions about commit

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I prevent accidental git commits to main or master branches?

To prevent accidental commits to protected branches, this Skill enforces branch safety by stopping commits on main or master and prompting to create context-named feature, fix, or refactor branches before staging and pushing changes.

How do I automate generating conventional commit messages for git changes?

You can automate generating conventional commit messages by applying this Skill to your local repository; it analyzes staged changes and automatically formats semantic commit messages, stages the changes, commits, and pushes to origin.

Does this git commit automation work inside linked worktrees?

Yes, this git commit automation works inside linked worktrees by automatically detecting the worktree context and avoiding creating or switching branches when operating within a worktree, ensuring safe version control operations.

What is the best way to safely push semantic commits to origin without force pushing?

The best way to safely push semantic commits without force pushing is using automated branch protection rules that generate conventional commit messages, stage changes, commit, and push to origin while explicitly avoiding force pushes.

How do I create a feature branch from main and push a fix commit in one step?

To create a feature branch from main and push a fix in one step, apply this Skill to your local repository; it detects if you are on main, creates a context-named branch, stages changes, generates a semantic commit, and pushes to origin.

Why do my conventional commits fail when working from a git worktree?

Conventional commits may fail in a git worktree if branch switching is attempted incorrectly; this Skill detects linked worktrees and avoids creating or switching branches to ensure version control operations remain safe and auditable.