Permalink
Browse files

Removed grabbing upstream infos from the left and right conflicts

This was a really good idea but it makes for unpredictable file names
when the conflicts stem from a rebase, cherry-pick, or unstash. I wish
there was a way to express this very useful data elsewhere, but for now
I'm going to pull it out.
  • Loading branch information...
1 parent 04603aa commit 5a7a8c6597505d06bd3c5b1739f3388189f730a2 @whiteinge committed Nov 15, 2012
Showing with 2 additions and 7 deletions.
  1. +2 −7 bin/diffconflicts
View
9 bin/diffconflicts
@@ -56,14 +56,9 @@ LOCAL=$3
REMOTE=$4
MERGED=$5
-# Extract the left (remote) and the right (local) name, if possible
-# If NF is not 2, this may be a rebase or the local/remotes name is not available
-LNAME=$( awk '/^<<<<<<< / { sub("/", ".", $2); if (NF == 2) print $2; exit }' $MERGED )
-RNAME=$( awk '/^>>>>>>> / { sub("/", ".", $2); if (NF == 2) print $2; exit }' $MERGED )
-
# Temporary files for left and right side
-LCONFL=$MERGED.REMOTE.$LNAME.$$.tmp
-RCONFL=$MERGED.LOCAL.$RNAME.$$.tmp
+LCONFL=$MERGED.REMOTE.$$.tmp
+RCONFL=$MERGED.LOCAL.$$.tmp
# Always delete our temp files; Git will handle it's own temp files
trap 'rm -f '$LCONFL' '$RCONFL SIGINT SIGTERM EXIT

0 comments on commit 5a7a8c6

Please sign in to comment.