t1200: prepare for merging with Fast-forward bikeshedding
[gitweb.git] / git-rebase--interactive.sh
index a1879e3ace72704086010dc5528d3897a91a6d02..53ad248ee505091d8e11cb9eb82ebb9b017b4262 100755 (executable)
@@ -416,7 +416,12 @@ do_next () {
                ;;
        *)
                warn "Unknown command: $command $sha1 $rest"
-               die_with_patch $sha1 "Please fix this in the file $TODO."
+               if git rev-parse --verify -q "$sha1" >/dev/null
+               then
+                       die_with_patch $sha1 "Please fix this in the file $TODO."
+               else
+                       die "Please fix this in the file $TODO."
+               fi
                ;;
        esac
        test -s "$TODO" && return