blob: 2308b6fde982ea6ac864885361d55c96306f8178 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
{- git-annex data types
- -}
module Types where
type Key = String
data Backend = Backend {
-- name of this backend
name :: String,
-- converts a filename to a key
getKey :: GitRepo -> FilePath -> IO (Maybe Key),
-- stores a file's contents to a key
storeFileKey :: GitRepo -> FilePath -> Key -> IO (Bool),
-- retrieves a key's contents to a file
retrieveKeyFile :: IO Key -> FilePath -> IO (Bool)
}
data GitRepo = GitRepo {
top :: FilePath,
remotes :: [GitRepo],
backends :: [Backend]
}
|