documentation: help: add "man.<tool>.path" config variable
[gitweb.git] / git-rebase--interactive.sh
index 4c3280a76ebe94c21fd4078c57ab03b6399d16ae..8aa73712ca11f4527f4b8d42bf3a14de2a16c39c 100755 (executable)
@@ -218,7 +218,7 @@ nth_string () {
 make_squash_message () {
        if test -f "$SQUASH_MSG"; then
                COUNT=$(($(sed -n "s/^# This is [^0-9]*\([1-9][0-9]*\).*/\1/p" \
-                       < "$SQUASH_MSG" | tail -n 1)+1))
+                       < "$SQUASH_MSG" | sed -ne '$p')+1))
                echo "# This is a combination of $COUNT commits."
                sed -e 1d -e '2,/^./{
                        /^$/d