diff options
author | Joey Hess <joey@kitenet.net> | 2010-10-12 15:44:54 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2010-10-12 15:44:54 -0400 |
commit | e53900a54597437818d785aa6b1683b3b49d2afb (patch) | |
tree | 3a1f37ca19be15361a2a26111eb80a4ad0ef697d /Annex.hs | |
parent | 4fbdb197d524720d1ea77795b33cb5d24152bce9 (diff) |
stub
Diffstat (limited to 'Annex.hs')
-rw-r--r-- | Annex.hs | 33 |
1 files changed, 32 insertions, 1 deletions
@@ -5,7 +5,12 @@ module Annex ( State, startAnnex, annexFile, - unannexFile + unannexFile, + annexGetFile, + annexWantFile, + annexDropFile, + annexPushRepo, + annexPullRepo ) where import System.Posix.Files @@ -83,6 +88,32 @@ unannexFile state file = do renameFile src file return () +{- Transfers the file from a remote. -} +annexGetFile :: State -> FilePath -> IO () +annexGetFile state file = do + alreadyannexed <- lookupBackend (backends state) (repo state) file + case (alreadyannexed) of + Nothing -> error $ "not annexed " ++ file + Just _ -> do error "not implemented" -- TODO + -- 1. find remote with file + -- 2. copy file from remote + +{- Indicates a file is wanted. -} +annexWantFile :: State -> FilePath -> IO () +annexWantFile state file = do error "not implemented" -- TODO + +{- Indicates a file is now wanted. -} +annexDropFile :: State -> FilePath -> IO () +annexDropFile state file = do error "not implemented" -- TODO + +{- Pushes all files to a remote repository. -} +annexPushRepo :: State -> String -> IO () +annexPushRepo state reponame = do error "not implemented" -- TODO + +{- Pulls all files from a remote repository. -} +annexPullRepo :: State -> String -> IO () +annexPullRepo state reponame = do error "not implemented" -- TODO + {- Sets up a git repo for git-annex. May be called repeatedly. -} gitPrep :: GitRepo -> IO () gitPrep repo = do |