summaryrefslogtreecommitdiff
path: root/BackendFile.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2010-10-13 02:31:24 -0400
committerGravatar Joey Hess <joey@kitenet.net>2010-10-13 02:31:24 -0400
commitd1071bd1fe879abb3ebb229f9347f7855a697b8c (patch)
treedb9df662b58f2b0762252f4d22b5cb244c8be978 /BackendFile.hs
parent490a3a828cbb5a4046178b36fc0f9fe0696d0e9d (diff)
autobugfixing!
Converted Key to a real data type and caught all the places where I used an unconverted filename as a key. Had to loose some sanity checks around whether something is already annexed, but I guess I can add those back other ways.
Diffstat (limited to 'BackendFile.hs')
-rw-r--r--BackendFile.hs5
1 files changed, 3 insertions, 2 deletions
diff --git a/BackendFile.hs b/BackendFile.hs
index 43ca2191c..15b23536b 100644
--- a/BackendFile.hs
+++ b/BackendFile.hs
@@ -15,12 +15,13 @@ backend = Backend {
-- direct mapping from filename to key
keyValue :: State -> FilePath -> IO (Maybe Key)
-keyValue state file = return $ Just file
+keyValue state file = return $ Just $ Key file
{- This backend does not really do any independant data storage,
- it relies on the file contents in .git/annex/ in this repo,
- and other accessible repos. So storing or removing a key is
- - a no-op. -}
+ - a no-op. TODO until support is added for git annex --push otherrepo,
+ - then these could implement that.. -}
dummyStore :: State -> FilePath -> Key -> IO (Bool)
dummyStore state file key = return True
dummyRemove :: State -> Key -> IO Bool