Commit Workflow
This skill automates the full commit workflow:
- •Creates a new branch (if not already on a feature branch)
- •Creates a Jira ticket (if not provided)
- •Commits changes (without Claude signature)
- •Creates a PR
Input
Optional argument: Jira ticket number (e.g., AC-12345) or description if no ticket exists yet.
Steps to Execute
Step 1: Check current branch status
git branch --show-current git status
Determine if:
- •Already on a feature branch (starts with
ben/) - skip branch creation - •On
main- need to create a new branch
Step 2: Analyze changes
git diff --staged git diff git log --oneline -5
Understand:
- •What files are changed
- •The nature of the changes (fix, feat, chore, refactor, docs, test)
- •Recent commit message style for consistency
Step 3: Create Jira ticket (if needed)
If no ticket number was provided in the argument:
Ask the user: "Should I create a Jira ticket for this work?"
If yes, create the ticket using the Atlassian MCP tools with these defaults:
- •Cloud ID:
d2499717-7d5b-4853-8d05-3cd88d45e753 - •Project:
AC - •Team: External Analytics (
c7e941f9-6983-47a0-bdaf-0aa50e9af528) - •Sprint: Fetch active sprint for External Analytics
- •Assignee: Ben Schepmans (
712020:ebbc8b7f-5fe8-4f29-9cd6-711330adeddb) - •Issue Type:
Task - •Status: Set to
In progressafter creation
If no, proceed without a ticket (will add pre-approved label to PR later).
Step 4: Create branch (if needed)
If on main, create a feature branch:
git checkout -b ben/<type>/<ticket>-<description>
Where:
- •
<type>isfeat,fix,chore,refactor,docs, ortest - •
<ticket>is the Jira ticket (e.g.,AC-12345) - omit if none - •
<description>is kebab-case summary (e.g.,remove-backend-visible-dependency)
Step 5: Stage and commit
Stage relevant files (be specific, avoid git add -A):
git add <specific-files>
Commit with the proper format:
git commit -m "<type>: AC-XXXXX description here"
Important:
- •NO Claude signature (no
Co-Authored-By) - •Commit message format:
<type>: AC-XXXXX description - •If no ticket, omit the ticket number:
<type>: description
Step 6: Push and create PR
git push -u origin <branch-name>
Create the PR:
gh pr create --title "<type>: AC-XXXXX description" --body "$(cat <<'EOF' ## Summary <1-3 bullet points describing the changes> ## Test plan <How to verify the changes work> EOF )" --assignee bnss
Then add copilot as reviewer:
gh pr edit <PR_NUMBER> --add-reviewer copilot
If no Jira ticket exists, add the pre-approved label:
gh pr edit <PR_NUMBER> --add-label pre-approved
Step 7: Return the PR URL
Provide the user with the PR URL so they can review it.
Conventions Reference
From CLAUDE.md:
- •Branch format:
ben/<type>/[optional-jira-ticket]<description> - •Commit format:
<type>: AC-XXXXX description here - •Types:
feat,fix,chore,refactor,docs,test - •No Claude signature in commits
- •PR assignee:
bnss - •Add copilot as reviewer
- •If no ticket: add
pre-approvedlabel to PR