Skip to content

Commit

Permalink
Merge branch 'jc/maint-am-keep' into maint
Browse files Browse the repository at this point in the history
* jc/maint-am-keep:
  Remove dead code from "git am"
  • Loading branch information
Junio C Hamano committed Dec 3, 2009
2 parents 957f5db + c970a6f commit 78b77c4
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions git-am.sh
Original file line number Diff line number Diff line change
Expand Up @@ -577,11 +577,12 @@ do
git cat-file commit "$commit" |
sed -e '1,/^$/d' >"$dotest/msg-clean"
else
SUBJECT="$(sed -n '/^Subject/ s/Subject: //p' "$dotest/info")"
case "$keep_subject" in -k) SUBJECT="[PATCH] $SUBJECT" ;; esac

(printf '%s\n\n' "$SUBJECT"; cat "$dotest/msg") |
git stripspace > "$dotest/msg-clean"
{
sed -n '/^Subject/ s/Subject: //p' "$dotest/info"
echo
cat "$dotest/msg"
} |
git stripspace > "$dotest/msg-clean"
fi
;;
esac
Expand Down

0 comments on commit 78b77c4

Please sign in to comment.