Skip to content

Commit a666ad6

Browse files
Fszontaghaider-chat-bot
andcommitted
chore: add script to fix non-English commit messages via rebase
Co-authored-by: aider (openrouter/x-ai/grok-code-fast-1) <aider@aider.chat>
1 parent e330a54 commit a666ad6

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed

fix_commit_messages.sh

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
#!/bin/bash
2+
3+
# Script to fix non-English commit messages via interactive rebase
4+
# Run this in your repository root. Assumes commits e330a54 and a822cff are on main branch.
5+
6+
# Check if we're on the main branch
7+
if [ "$(git branch --show-current)" != "main" ]; then
8+
echo "Error: Not on main branch. Switch to main and try again."
9+
exit 1
10+
fi
11+
12+
# Get the hash of the commit before a822cff (to rebase from there)
13+
# Assuming a822cff is the older commit, rebase from its parent.
14+
# If a822cff is the first commit, adjust accordingly.
15+
BASE_COMMIT=$(git rev-parse a822cff~1 2>/dev/null || echo "HEAD~2")
16+
17+
# Start interactive rebase from the base commit to edit the last two commits
18+
git rebase -i "$BASE_COMMIT"
19+
20+
# After running, your editor will open with instructions.
21+
# Change "pick" to "edit" for the commits you want to amend:
22+
# - For a822cff: Keep as "pick" (already English).
23+
# - For e330a54: Change to "edit", then run:
24+
# git commit --amend -m "fix: Implementation of missing methods in SymbolContainer"
25+
# git rebase --continue
26+
27+
echo "Rebase initiated. Follow the editor instructions to edit the messages."
28+
echo "After editing, run 'git rebase --continue' for each edited commit."

0 commit comments

Comments
 (0)