Automate the Git commit and push process by intelligently analyzing file changes, generating semantic commit messages with file paths, and providing an interactive command execution workflow. The workflow opens a new terminal, checks Git status, analyzes changes to create descriptive commit messages, lists commands for user review, and executes Git operations step by step with user confirmation.
Use the execute_command
tool to open a new terminal session.
Use the execute_command
tool to execute git status
to check current repository state.
Analyze the output to understand the scope of changes in the current working directory. you should ignore dev.ts file.
For each changed file identified in git status:
read_file
tool to examine the content of modified files if needed for contextBased on the file changes and any user-provided context information:
feat: add new workflow creation process in .clinerules/workflows/create-new-workflow.md
fix: resolve authentication issue in src/API/security/userActions.ts
docs: update README.md with installation instructions
Ensure the commit message is descriptive and includes relevant file paths for clarity.
Generate the complete list of Git commands to be executed:
git add .
git commit -m "generated commit message with file paths"
git push
Display the command list clearly to the user for review and confirmation.
Show the generated commit message prominently so the user can verify its accuracy.
Use the ask_followup_question
tool to ask the user for confirmation with clickable options:
Handle user response:
Execute git add .
execute_command
tool to run git add .
Execute git commit
execute_command
tool to run git commit -m "final commit message"
Execute git push
execute_command
tool to run git push
Final Confirmation
attempt_completion
tool to present the final resultsgit commit -m
) and ignore user-defined git aliases