hgrev-0.1.2: Compile Mercurial (hg) version info into Haskell code

Safe HaskellNone
LanguageHaskell2010

Development.HgRev

Synopsis

Documentation

hgRevState Source

Arguments

:: FilePath

Path anywhere within the repository

-> IO (Maybe (HgRev, HgState))

Nothing is returned if no repo or hg binary are found

Get the hg revision and working directory state for a given repo.

hgRev Source

Arguments

:: FilePath

Path anywhere within the repository

-> IO (Maybe HgRev)

Nothing is returned if no repo or hg binary are found

Get the hg revision for a given repo.

hgState Source

Arguments

:: FilePath

Path anywhere within the repository

-> IO (Maybe HgState)

Nothing is returned if no repo or hg binary are found

Get the hg working directory state for a given repo.

hgShortRev :: HgRev -> String Source

Get the hg short revision which is the first 12 hex characters of the hash.

hgIsDirty :: HgState -> Bool Source

Bool indication of dirty working directory state.

data HgRev Source

Constructors

HgRev 

Fields

hgRevision :: String

Universally unique revision hash

hgBranch :: String

Branch name

hgTags :: [String]

Tags

hgBookmarks :: [String]

Bookmarks

data HgState Source

Constructors

Clean

No uncommitted changes in working directory

Dirty

Uncommitted changes exist in working directory