summaryrefslogtreecommitdiff
path: root/Command
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2014-02-18 21:02:27 -0400
committerGravatar Joey Hess <joey@kitenet.net>2014-02-18 21:09:25 -0400
commitd8cc840cc7fd9d543486b7a86426eb4bc444b5aa (patch)
treea524b4d7ff9c24e0839beec5546e4a4a40cf7166 /Command
parent935f5ed55b1ed9a218955fdd34cb40db3b1c9425 (diff)
fixed vpop
Diffstat (limited to 'Command')
-rw-r--r--Command/VCycle.hs1
-rw-r--r--Command/VPop.hs7
2 files changed, 5 insertions, 3 deletions
diff --git a/Command/VCycle.hs b/Command/VCycle.hs
index c1bee30b6..b41e099a4 100644
--- a/Command/VCycle.hs
+++ b/Command/VCycle.hs
@@ -27,6 +27,7 @@ start = go =<< currentView
where
go Nothing = error "Not in a view."
go (Just v) = do
+ showStart "vcycle" ""
let v' = v { viewComponents = vcycle [] (viewComponents v) }
if v == v'
then do
diff --git a/Command/VPop.hs b/Command/VPop.hs
index 52c2b7f0c..e62c2414a 100644
--- a/Command/VPop.hs
+++ b/Command/VPop.hs
@@ -28,10 +28,11 @@ start = go =<< currentView
where
go Nothing = error "Not in a view."
go (Just v) = do
- vs <- dropWhile (/= v) . filter (sameparentbranch v)
- <$> recentViews
+ showStart "vpop" ""
+ removeView v
+ vs <- filter (sameparentbranch v) <$> recentViews
case vs of
- (_v:oldv:_) -> next $ next $
+ (oldv:_) -> next $ next $ do
checkoutViewBranch oldv (return . branchView)
_ -> next $ next $
inRepo $ Git.Command.runBool