darcs-2.8.5: a distributed, interactive, smart revision control system

Safe HaskellNone
LanguageHaskell98

Darcs.Repository.Format

Synopsis

Documentation

newtype RepoFormat Source

RepoFormat is the representation of the format of a repository. Each sublist corresponds to a line in the format file. Each line is decomposed into words.

Constructors

RF [[ByteString]] 

Instances

identifyRepoFormat :: String -> IO RepoFormat Source

identifyRepoFormat URL identifies the format of the repository at the given address. Fails if we weren't able to identify the format.

tryIdentifyRepoFormat :: String -> IO (Either String RepoFormat) Source

tryIdentifyRepoFormat URL identifies the format of the repository at the given address. Return Left reason if it fails, where reason explains why we weren't able to identify the format.

writeRepoFormat :: RepoFormat -> FilePath -> IO () Source

writeRepoFormat writes the repo format to the given file.

writeProblem :: RepoFormat -> Maybe String Source

writeProblem form tells if we can write to a repo in format form. It returns Nothing if there's no problem writing to such a repository.

readProblem :: RepoFormat -> Maybe String Source

readProblem form tells if we can read from a repo in format form. It returns Nothing if there's no problem reading from such a repository.

readfromAndWritetoProblem :: RepoFormat -> RepoFormat -> Maybe String Source

readfromAndWritetoProblem form tells if we can read from and write to a repo in format form. It returns Nothing if there's no problem reading and writing to such a repository.