Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data ApplyDir
- applyToHashedPristine :: (Apply p, ApplyState p ~ Tree) => ApplyDir -> PristineHash -> p wX wY -> IO PristineHash
- applyToTentativePristine :: (ApplyState q ~ Tree, Apply q, ShowPatch q) => Repository rt p wR wU wT -> ApplyDir -> Verbosity -> q wT wY -> IO ()
- applyToTentativePristineCwd :: (ApplyState p ~ Tree, Apply p) => ApplyDir -> p wX wY -> IO ()
- readHashedPristineRoot :: Repository rt p wR wU wT -> IO (Maybe PristineHash)
- pokePristineHash :: PristineHash -> ByteString -> Doc
- peekPristineHash :: ByteString -> PristineHash
- createPristineDirectoryTree :: Repository rt p wR wU wT -> FilePath -> WithWorkingDir -> IO ()
- createPartialsPristineDirectoryTree :: Repository rt p wR wU wT -> [AnchoredPath] -> FilePath -> IO ()
- withRecorded :: Repository rt p wR wU wT -> ((AbsolutePath -> IO a) -> IO a) -> (AbsolutePath -> IO a) -> IO a
- withTentative :: Repository rt p wR wU wT -> ((AbsolutePath -> IO a) -> IO a) -> (AbsolutePath -> IO a) -> IO a
Documentation
applyToHashedPristine :: (Apply p, ApplyState p ~ Tree) => ApplyDir -> PristineHash -> p wX wY -> IO PristineHash Source #
applyToHashedPristine
takes a root hash, a patch p
and attempts to
apply the patch to the Tree
identified by h
. If we encounter an old,
size-prefixed pristine, we first convert it to the non-size-prefixed format,
then apply the patch.
applyToTentativePristine :: (ApplyState q ~ Tree, Apply q, ShowPatch q) => Repository rt p wR wU wT -> ApplyDir -> Verbosity -> q wT wY -> IO () Source #
applyToTentativePristine applies a patch p
to the tentative pristine
tree, and updates the tentative pristine hash
applyToTentativePristineCwd :: (ApplyState p ~ Tree, Apply p) => ApplyDir -> p wX wY -> IO () Source #
readHashedPristineRoot :: Repository rt p wR wU wT -> IO (Maybe PristineHash) Source #
readHashedPristineRoot attempts to read the pristine hash from the current inventory, returning Nothing if it cannot do so.
pokePristineHash :: PristineHash -> ByteString -> Doc Source #
Replace the pristine hash at the start of a raw, unparsed HeadInventory
or add it if none is present.
createPristineDirectoryTree :: Repository rt p wR wU wT -> FilePath -> WithWorkingDir -> IO () Source #
grab the pristine hash of _darcs/hash_inventory, and retrieve whole pristine tree, possibly writing a clean working tree in the process.
createPartialsPristineDirectoryTree :: Repository rt p wR wU wT -> [AnchoredPath] -> FilePath -> IO () Source #
Used by the commands dist and diff
withRecorded :: Repository rt p wR wU wT -> ((AbsolutePath -> IO a) -> IO a) -> (AbsolutePath -> IO a) -> IO a Source #
withTentative :: Repository rt p wR wU wT -> ((AbsolutePath -> IO a) -> IO a) -> (AbsolutePath -> IO a) -> IO a Source #