| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Development.HgRev.TH
Synopsis
- type FormatFn = HgRev -> HgState -> String
- hgRevStateTHDir :: FilePath -> FormatFn -> ExpQ
- hgRevStateTH :: FormatFn -> ExpQ
- defFormat :: FormatFn
- jsonFormat :: FormatFn
- newtype HgRevState = HgRevState (HgRev, HgState)
Documentation
type FormatFn = HgRev -> HgState -> String Source #
Function to format hg rev and state info for printing
hgRevStateTHDir :: FilePath -> FormatFn -> ExpQ Source #
Apply a format function and return a Template Haskell spliced string for compiling into code.
Since: 0.2.5
hgRevStateTH :: FormatFn -> ExpQ Source #
Apply a format function and return a Template Haskell spliced string for compiling into code.
defFormat :: FormatFn Source #
long: d9d3a1172a1d919b3056b435891081c0d7d00599 short: d9d3a1172a1d clean: true
jsonFormat :: FormatFn Source #
{
"clean": true,
"short": "d9d3a1172a1d",
"branch": "default",
"bookmarks": [],
"long": "d9d3a1172a1d919b3056b435891081c0d7d00599",
"tags": [
"tip"
]
}newtype HgRevState Source #
Constructors
| HgRevState (HgRev, HgState) |
Instances
| ToJSON HgRevState Source # | |
Defined in Development.HgRev.TH Methods toJSON :: HgRevState -> Value # toEncoding :: HgRevState -> Encoding # toJSONList :: [HgRevState] -> Value # toEncodingList :: [HgRevState] -> Encoding # | |