一键导入
git-commit-awareness
Detect when work is commit-ready and suggest Conventional Commit messages automatically.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Detect when work is commit-ready and suggest Conventional Commit messages automatically.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | Git Commit Awareness |
| description | Detect when work is commit-ready and suggest Conventional Commit messages automatically. |
| last_verified | "2026-01-23T00:00:00.000Z" |
| applicable_sdk | Android 14+ (API 34+) |
| dependencies | ["codebase-aware-implementation","ai-collab-workflow"] |
Last Verified: 2026-01-23 Applicable SDK: Android 14+ (API 34+) Dependencies: codebase-aware-implementation, ai-collab-workflow
Proactively recognize when a feature is complete and automatically suggest or create git commits with meaningful messages.
A feature is "commit-ready" when ALL of these are true:
Functional Completeness
Code Quality
println() or temporary codeTesting Done
Scope Boundary
Follow Conventional Commits:
<type>(<scope>): <subject>
[optional body]
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
| Type | When to Use | Example |
|---|---|---|
feat | New feature or enhancement | feat(settings): add OLED burn-in protection toggle |
fix | Bug fix | fix(rotation): eliminate black flash on orientation change |
refactor | Code restructuring (no behavior change) | refactor(widget): extract base WidgetProvider class |
perf | Performance improvement | perf(rendering): cache text bounds to reduce allocations |
style | Code style/formatting (no logic change) | style: apply ktlint formatting |
docs | Documentation only | docs: update README with widget installation steps |
test | Add or fix tests | test(clock): add unit tests for time formatting |
chore | Build/tooling changes | chore: update Gradle to 8.10 |
Use project-specific scopes:
settings - Settings UI/logicwidget - Widget providersclock - Clock renderingtheme - Theme systemanimation - Animation logicbuild - Build configurationAfter implementing a feature, ask yourself:
✓ Does the app build?
✓ Did I test the feature?
✓ Is this a logical stopping point?
✓ Are there no temporary hacks left?
If all YES → Trigger commit awareness
# 1. Check git status
git status
# 2. Review changes
git diff
# 3. Check recent commits for message style
git log --oneline -5
Template:
I've completed implementing [feature description]. This is a good commit point.
Should I create a commit with this message?
---
[proposed commit message]
---
If you approve, I'll:
1. Stage the relevant files
2. Create the commit
3. Verify with git log
# Stage files (be selective!)
git add [specific files]
# Create commit with heredoc for multi-line message
git commit -m "$(cat <<'EOF'
feat(scope): concise description
Optional body explaining why this change was made.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
EOF
)"
# Verify
git log -1 --stat
Scenario: Just added OLED protection toggle
# Detect: Feature complete, tested, no TODOs
# Propose:
feat(settings): add OLED burn-in protection toggle
Implements pixel shifting with configurable interval to prevent
OLED burn-in on always-on clock displays.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Scenario: Fixed rotation black flash
fix(rotation): eliminate black flash during orientation change
Use windowBackground with hardcoded color instead of theme attribute
to prevent flash when activity recreates.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Scenario: Extracted widget base class
refactor(widget): extract BaseWidgetProvider class
Reduces duplication across 5 widget providers by extracting
common update logic into shared base class.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Bad:
feat: add OLED toggle, fix rotation bug, update README
Good: Split into 3 commits:
feat(settings): add OLED burn-in protection toggle
fix(rotation): eliminate black flash
docs: update README with new OLED feature
// TODO: Remove debug logging
Log.d("DEBUG", "This is temporary")
Action: Remove debug code BEFORE committing
./gradlew build
# > Task :app:compileDebugKotlin FAILED
Action: Fix build errors BEFORE committing
./gradlew installDebuggit diffRule of Thumb: If you can't describe the change in one sentence → it's too big, split it.
# Quick status check
git status --short
# See what changed
git diff --stat
# Check for untracked files
git ls-files --others --exclude-standard
# Check if message follows conventions
echo "feat(settings): add toggle" | grep -E "^(feat|fix|refactor|perf|style|docs|test|chore)(\(.+\))?: .+"
# See last commit details
git show HEAD
# See commit with file changes
git log -1 --stat
# Amend last commit if needed (ONLY if not pushed!)
git commit --amend
git commit -m "WIP"
git commit -m "more changes"
git commit -m "fix"
Why Bad: Pollutes history, hard to understand what changed
100 files changed, 5000 insertions(+), 3000 deletions(-)
Why Bad: Impossible to review, risky to revert
git commit -m "update code"
git commit -m "fix bug"
git commit -m "changes"
Why Bad: Future developers (including you) won't understand what changed
Before creating a commit, verify:
Guidance for creating effective modular skills for Claude. Use when creating or refining skills to ensure they are concise, follow progressive disclosure patterns, and provide appropriate degrees of freedom.
Guidelines for ensuring smooth and race-condition-free theme transitions in Android, specifically regarding icon tinting and state management.
Best practices for effective human-AI pair programming and communication
Clarify touch-target vs visual size when users ask to resize buttons without changing icons.
Choose whether the outer container acts as the touch proxy or remains a layout placeholder to control hit targets.
Best practices for 60fps custom View rendering with zero allocation in onDraw