Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
-
data
SourceRepo
=
SourceRepo
{
- repoKind :: RepoKind
- repoType :: Maybe RepoType
- repoLocation :: Maybe String
- repoModule :: Maybe String
- repoBranch :: Maybe String
- repoTag :: Maybe String
- repoSubdir :: Maybe FilePath
- data RepoKind
- data RepoType
- knownRepoTypes :: [ RepoType ]
- emptySourceRepo :: RepoKind -> SourceRepo
- classifyRepoType :: String -> RepoType
- classifyRepoKind :: String -> RepoKind
Documentation
data SourceRepo Source #
Information about the source revision control system for a package.
When specifying a repo it is useful to know the meaning or intention of the
information as doing so enables automation. There are two obvious common
purposes: one is to find the repo for the latest development version, the
other is to find the repo for this specific release. The
ReopKind
specifies which one we mean (or another custom one).
A package can specify one or the other kind or both. Most will specify just a head repo but some may want to specify a repo to reconstruct the sources for this package release.
The required information is the
RepoType
which tells us if it's using
Darcs
,
Git
for example. The
repoLocation
and other details are
interpreted according to the repo type.
SourceRepo | |
|
Instances
What this repo info is for, what it represents.
RepoHead |
The repository for the "head" or development version of the project. This repo is where we should track the latest development activity or the usual repo people should get to contribute patches. |
RepoThis |
The repository containing the sources for this exact package version or release. For this kind of repo a tag should be given to give enough information to re-create the exact sources. |
RepoKindUnknown String |
Instances
An enumeration of common source control systems. The fields used in the
SourceRepo
depend on the type of repo. The tools and methods used to
obtain and track the repo depend on the repo type.
Instances
knownRepoTypes :: [ RepoType ] Source #
emptySourceRepo :: RepoKind -> SourceRepo Source #
classifyRepoType :: String -> RepoType Source #
classifyRepoKind :: String -> RepoKind Source #