metadata: Fix reversion introduced in 5.20150727 that caused display of metadata to not work.

This commit is contained in:
Joey Hess 2015-08-11 13:19:01 -04:00
parent d54c9c46da
commit 0f66f766b0
3 changed files with 22 additions and 18 deletions

View file

@ -33,11 +33,11 @@ withFilesInGit :: (FilePath -> CommandStart) -> CmdParams -> CommandSeek
withFilesInGit a params = seekActions $ prepFiltered a $
seekHelper LsFiles.inRepo params
withFilesInGitNonRecursive :: (FilePath -> CommandStart) -> CmdParams -> CommandSeek
withFilesInGitNonRecursive a params = ifM (Annex.getState Annex.force)
withFilesInGitNonRecursive :: String -> (FilePath -> CommandStart) -> CmdParams -> CommandSeek
withFilesInGitNonRecursive needforce a params = ifM (Annex.getState Annex.force)
( withFilesInGit a params
, if null params
then needforce
then error needforce
else seekActions $ prepFiltered a (getfiles [] params)
)
where
@ -51,8 +51,7 @@ withFilesInGitNonRecursive a params = ifM (Annex.getState Annex.force)
[] -> do
void $ liftIO $ cleanup
getfiles c ps
_ -> needforce
needforce = error "Not recursively setting metadata. Use --force to do that."
_ -> error needforce
withFilesNotInGit :: Bool -> (FilePath -> CommandStart) -> CmdParams -> CommandSeek
withFilesNotInGit skipdotfiles a params