summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CmdLine/Seek.hs4
-rw-r--r--Command/FindRef.hs3
2 files changed, 4 insertions, 3 deletions
diff --git a/CmdLine/Seek.hs b/CmdLine/Seek.hs
index 66cd985f4..556a108eb 100644
--- a/CmdLine/Seek.hs
+++ b/CmdLine/Seek.hs
@@ -77,12 +77,12 @@ withFilesNotInGit skipdotfiles a params
go l = seekActions $ prepFiltered a $
return $ concat $ segmentPaths params l
-withFilesInRefs :: (FilePath -> Key -> CommandStart) -> CmdParams -> CommandSeek
+withFilesInRefs :: (FilePath -> Key -> CommandStart) -> [Git.Ref] -> CommandSeek
withFilesInRefs a = mapM_ go
where
go r = do
matcher <- Limit.getMatcher
- (l, cleanup) <- inRepo $ LsTree.lsTree (Git.Ref r)
+ (l, cleanup) <- inRepo $ LsTree.lsTree r
forM_ l $ \i -> do
let f = getTopFilePath $ LsTree.file i
v <- catKey (LsTree.sha i)
diff --git a/Command/FindRef.hs b/Command/FindRef.hs
index cb14371e0..93315bcef 100644
--- a/Command/FindRef.hs
+++ b/Command/FindRef.hs
@@ -9,6 +9,7 @@ module Command.FindRef where
import Command
import qualified Command.Find as Find
+import qualified Git
cmd :: Command
cmd = withGlobalOptions nonWorkTreeMatchingOptions $ Find.mkCommand $
@@ -17,4 +18,4 @@ cmd = withGlobalOptions nonWorkTreeMatchingOptions $ Find.mkCommand $
paramRef (seek <$$> Find.optParser)
seek :: Find.FindOptions -> CommandSeek
-seek o = Find.start o `withFilesInRefs` Find.findThese o
+seek o = Find.start o `withFilesInRefs` (map Git.Ref $ Find.findThese o)