chiark
/
gitweb
/
~mdw
/
stgit
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Revert 'Changed rebasing safety check to look for reachability of
[stgit]
/
stgit
/
commands
/
rebase.py
diff --git
a/stgit/commands/rebase.py
b/stgit/commands/rebase.py
index d132b60bce951d60b724e1fd767822074524fd4c..2f0e6605f7c012e5431077e740fad31c7e276493 100644
(file)
--- a/
stgit/commands/rebase.py
+++ b/
stgit/commands/rebase.py
@@
-52,6
+52,10
@@
def func(parser, options, args):
check_conflicts()
check_head_top_equal()
check_conflicts()
check_head_top_equal()
+ # ensure an exception is raised before popping on non-existent target
+ if git_id(args[0]) == None:
+ raise GitException, 'Unknown revision: %s' % git_id
+
applied = prepare_rebase(real_rebase=True, force=options.force)
rebase(args[0])
post_rebase(applied, options.nopush, options.merged)
applied = prepare_rebase(real_rebase=True, force=options.force)
rebase(args[0])
post_rebase(applied, options.nopush, options.merged)