2011-06-22 19:58:30 +00:00
|
|
|
{- git-annex BranchState data type
|
|
|
|
-
|
|
|
|
- Copyright 2011 Joey Hess <joey@kitenet.net>
|
|
|
|
-
|
|
|
|
- Licensed under the GNU GPL version 3 or higher.
|
|
|
|
-}
|
|
|
|
|
|
|
|
module Types.BranchState where
|
|
|
|
|
2011-06-30 01:23:40 +00:00
|
|
|
import System.IO
|
|
|
|
|
2011-06-22 19:58:30 +00:00
|
|
|
data BranchState = BranchState {
|
2011-06-30 01:23:40 +00:00
|
|
|
branchUpdated :: Bool, -- has the branch been updated this run?
|
|
|
|
|
|
|
|
-- (from, to) handles used to talk to a git-cat-file process
|
|
|
|
catFileHandles :: Maybe (Handle, Handle),
|
|
|
|
|
|
|
|
-- the content of one file is cached
|
2011-06-22 19:58:30 +00:00
|
|
|
cachedFile :: Maybe FilePath,
|
|
|
|
cachedContent :: String
|
|
|
|
}
|
|
|
|
|
|
|
|
startBranchState :: BranchState
|
2011-06-30 01:23:40 +00:00
|
|
|
startBranchState = BranchState False Nothing Nothing ""
|