~mdw
/
stgit
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Optimize stg goto in the pop case.
[stgit]
/
stgit
/
commands
/
goto.py
diff --git
a/stgit/commands/goto.py
b/stgit/commands/goto.py
index
1b62d1c
..
e129b8d
100644
(file)
--- a/
stgit/commands/goto.py
+++ b/
stgit/commands/goto.py
@@
-45,11
+45,11
@@
def func(parser, options, args):
check_head_top_equal()
applied = crt_series.get_applied()
check_head_top_equal()
applied = crt_series.get_applied()
- applied.reverse()
unapplied = crt_series.get_unapplied()
patch = args[0]
if patch in applied:
unapplied = crt_series.get_unapplied()
patch = args[0]
if patch in applied:
+ applied.reverse()
patches = applied[:applied.index(patch)]
pop_patches(patches)
elif patch in unapplied:
patches = applied[:applied.index(patch)]
pop_patches(patches)
elif patch in unapplied: