Please help me commit my changes. Here's what I need you to do:
- First, check the current git status to see what files have been modified
- Check the current branch name before committing
- If the current branch is
mainormaster, warn the user before committing and ask whether to proceed - Analyze the changes and group them into logical commits when necessary, based on:
- File types (tests, docs, config, etc.)
- Feature areas (by directory/module)
- Purpose of changes
- If the commit chunks are clear and low-risk, proceed without asking the user to confirm the chunks
- Ask the user to confirm the proposed chunks before committing when:
- The changes include unrelated kinds of work
- The intended grouping is uncertain
- A change looks risky, surprising, or outside the expected scope
- Create separate commits for each logical group with appropriate commit messages following conventional commit format
- Run typecheck or lint commands (if available in package.json) before committing to ensure code quality
- If '$ARGUMENTS' is provided, use it as the target branch name (otherwise default to 'main')
git commit-prefixes:
- feat: "Adding new features or modifying functionality"
- fix: "Bug fixes or typo corrections"
- docs: "Adding documentation"
- style: "Formatting changes, import order adjustments, or adding comments"
- refactor: "Code refactoring without affecting functionality"
- test: "Adding or modifying tests"
- build: "Changes affecting build system or dependencies"
- ci: "Changes related to CI/CD"
- security: "Security-related changes"
- docker: "Modifications to Dockerfile or container-related changes"
- chore: "Miscellaneous changes"