renaming
This commit is contained in:
parent
4c9ad1de46
commit
7a42a47902
17 changed files with 31 additions and 34 deletions
|
@ -84,7 +84,7 @@ keyOpt s = case parseURI s of
|
|||
Nothing -> giveup $ "bad key/url " ++ s
|
||||
|
||||
perform :: Key -> FilePath -> CommandPerform
|
||||
perform key file = lookupFileNotHidden (toRawFilePath file) >>= \case
|
||||
perform key file = lookupKeyNotHidden (toRawFilePath file) >>= \case
|
||||
Nothing -> ifM (liftIO $ doesFileExist file)
|
||||
( hasothercontent
|
||||
, do
|
||||
|
|
|
@ -168,7 +168,7 @@ parseJSONInput i = case eitherDecode (BU.fromString i) of
|
|||
startBatch :: (Either RawFilePath Key, MetaData) -> CommandStart
|
||||
startBatch (i, (MetaData m)) = case i of
|
||||
Left f -> do
|
||||
mk <- lookupFile f
|
||||
mk <- lookupKey f
|
||||
case mk of
|
||||
Just k -> go k (mkActionItem (k, AssociatedFile (Just f)))
|
||||
Nothing -> giveup $ "not an annexed file: " ++ fromRawFilePath f
|
||||
|
|
|
@ -136,7 +136,7 @@ send ups fs = do
|
|||
let addlist f o = whenM (matcher $ MatchingFile $ FileInfo f f) $
|
||||
liftIO $ hPutStrLn h o
|
||||
forM_ fs' $ \f -> do
|
||||
mk <- lookupFile f
|
||||
mk <- lookupKey f
|
||||
case mk of
|
||||
Nothing -> noop
|
||||
Just k -> withObjectLoc k $
|
||||
|
|
|
@ -439,7 +439,7 @@ randKey sz = withTmpFile "randkey" $ \f h -> do
|
|||
return k
|
||||
|
||||
getReadonlyKey :: Remote -> FilePath -> Annex Key
|
||||
getReadonlyKey r f = lookupFile (toRawFilePath f) >>= \case
|
||||
getReadonlyKey r f = lookupKey (toRawFilePath f) >>= \case
|
||||
Nothing -> giveup $ f ++ " is not an annexed file"
|
||||
Just k -> do
|
||||
unlessM (inAnnex k) $
|
||||
|
|
|
@ -215,7 +215,7 @@ withKeysReferenced' mdir initial a = do
|
|||
Just dir -> inRepo $ LsFiles.inRepo [] [toRawFilePath dir]
|
||||
go v [] = return v
|
||||
go v (f:fs) = do
|
||||
mk <- lookupFile f
|
||||
mk <- lookupKey f
|
||||
case mk of
|
||||
Nothing -> go v fs
|
||||
Just k -> do
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue