Commit

From deadlock-mod-manager/deadlock-mod-manager · View interactive version

Commit is an AI agent skill from the GitHub repository deadlock-mod-manager/deadlock-mod-manager. Commit staged changes with a conventional commit message that passes commitlint.

How to use this skill

Skill file

Commit Staged Changes

Generate a conventional commit message and commit staged changes, respecting the project's commitlint configuration.

Branch: Commit on the current branch. Do not create or switch to a feature branch unless the user asks (see git-conventions — _Current branch (agents)_).

Instructions

1. Gather Context

Run the single git command from git-conventions to gather all context:

echo "=== BRANCH ===" && git rev-parse --abbrev-ref HEAD && echo "=== STAGED FILES ===" && git diff --staged --stat && echo "=== STAGED CHANGES ===" && git diff --staged

2. Analyze & Generate

From the gathered information:

3. Present & Execute

Show the generated commit message in a code block:

type(scope): description

Optional body text

Closes #123

Explain the ticket number, type, and scope chosen.

Then execute the commit:

For commits with body:

git commit -m "type(scope): description" -m "Body paragraph" -m "Closes #GITHUB_ISSUE"

For commits without body:

git commit -m "type(scope): description"

After committing, show the commit hash and confirm success.

4. Error Handling

If the commit fails (e.g., commitlint validation fails):

Key Points

Example Usage

User: "commit", "commit staged changes", or /commit

Response:

  1. Run single git command to gather context
  2. Extract ticket number, analyze changes, determine type and scope
  3. Generate properly formatted commit message
  4. Show the message in a code block
  5. Execute the git commit command
  6. Confirm success with commit hash
Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.