mq: support "qimport --existing --name renametothis thatexistingpatch"
Before this change, the command would abort with a not too clear "patch
renametothis does not exist" error.
This change makes:
qimport --existing --name renametothis thatexistingpatch
equivalent to:
qimport --existing thatexistingpatch; qrename thatexistingpatch renametothis
#!/bin/sh
hg init
touch a
hg add a
hg ci -m "a" -d "1000000 0"
echo 123 > b
hg add b
hg diff --nodates
hg diff --nodates -r tip
echo foo > a
hg diff --nodates
hg diff -r ""
hg diff -r tip -r ""
true