Safe Haskell | None |
---|---|
Language | Haskell2010 |
This submodule contains all type definitions and Dhall counterparts.
Synopsis
- data Virtual = Virtual {}
- data Target
- data Action = Action {}
- type Generator = [Target] -> [Target] -> Maybe Text
- data Rule = Rule {}
- data Call = Call {}
- data Stmt
- stmt :: Decoder Stmt
- readStmts :: MonadIO m => FilePath -> m [Stmt]
- data Config = Config {}
- stmtsToConfig :: [Stmt] -> Config
- readConfig :: MonadIO m => FilePath -> m Config
- data Watch = Watch {}
Documentation
A virtual target is one that is not backed up by a file, but rather by something that could be a file. One example would be an entry in an sqlite database. This may be a future feature.
Instances
Eq Virtual # | |
Show Virtual # | |
Generic Virtual # | |
FromDhall Virtual # | |
Defined in Milkshake.Data | |
ToDhall Virtual # | |
Defined in Milkshake.Data injectWith :: InputNormalizer -> Encoder Virtual | |
type Rep Virtual # | |
Defined in Milkshake.Data type Rep Virtual = D1 ('MetaData "Virtual" "Milkshake.Data" "milkshake-0.1.0.0-inplace" 'False) (C1 ('MetaCons "Virtual" 'PrefixI 'True) (S1 ('MetaSel ('Just "name") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text) :*: (S1 ('MetaSel ('Just "exists") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text) :*: S1 ('MetaSel ('Just "content") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text)))) |
A target is either a file, some virtual content, or a phony target.
Instances
Eq Target # | |
Show Target # | |
Generic Target # | |
FromDhall Target # | |
Defined in Milkshake.Data | |
ToDhall Target # | |
Defined in Milkshake.Data injectWith :: InputNormalizer -> Encoder Target | |
type Rep Target # | |
Defined in Milkshake.Data type Rep Target = D1 ('MetaData "Target" "Milkshake.Data" "milkshake-0.1.0.0-inplace" 'False) (C1 ('MetaCons "File" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text)) :+: (C1 ('MetaCons "Generic" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Virtual)) :+: C1 ('MetaCons "Phony" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text)))) |
An Action
is a node in our workflow.
Instances
Show Action # | |
Generic Action # | |
FromDhall Action # | |
Defined in Milkshake.Data | |
type Rep Action # | |
Defined in Milkshake.Data type Rep Action = D1 ('MetaData "Action" "Milkshake.Data" "milkshake-0.1.0.0-inplace" 'False) (C1 ('MetaCons "Action" 'PrefixI 'True) (S1 ('MetaSel ('Just "target") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Target]) :*: (S1 ('MetaSel ('Just "dependency") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Target]) :*: S1 ('MetaSel ('Just "script") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Text))))) |
A Rule
is a parametric Action
. Given a list of targets and dependencies,
the generator creates the corresponding script.
Instances
Generic Rule # | |
FromDhall Rule # | |
Defined in Milkshake.Data | |
type Rep Rule # | |
Defined in Milkshake.Data type Rep Rule = D1 ('MetaData "Rule" "Milkshake.Data" "milkshake-0.1.0.0-inplace" 'False) (C1 ('MetaCons "Rule" 'PrefixI 'True) (S1 ('MetaSel ('Just "name") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text) :*: S1 ('MetaSel ('Just "gen") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Generator))) |
The Call
is like a function call, where the Rule
is the function
and $sel:target:Action
and dependecy
are the arguments.
Instances
Show Call # | |
Generic Call # | |
FromDhall Call # | |
Defined in Milkshake.Data | |
type Rep Call # | |
Defined in Milkshake.Data type Rep Call = D1 ('MetaData "Call" "Milkshake.Data" "milkshake-0.1.0.0-inplace" 'False) (C1 ('MetaCons "Call" 'PrefixI 'True) (S1 ('MetaSel ('Just "name") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text) :*: (S1 ('MetaSel ('Just "target") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Target]) :*: S1 ('MetaSel ('Just "dependency") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Target])))) |
The Milkshake script is an unordered list of statements. The Stmt
type
encodes statements in a Milkshake script.
To decode a list of Milkshake statements from the Dhall configuration use this decoder.
>>>
input (list stmt) "(entangled.dhall).milkshake"
Transposed data record of a list of Stmt
.
Instances
Generic Config # | |
Semigroup Config # | |
Monoid Config # | |
type Rep Config # | |
Defined in Milkshake.Data type Rep Config = D1 ('MetaData "Config" "Milkshake.Data" "milkshake-0.1.0.0-inplace" 'False) (C1 ('MetaCons "Config" 'PrefixI 'True) ((S1 ('MetaSel ('Just "rules") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Map Text Generator)) :*: (S1 ('MetaSel ('Just "triggers") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Call]) :*: S1 ('MetaSel ('Just "actions") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Action]))) :*: (S1 ('MetaSel ('Just "includes") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [FilePath]) :*: (S1 ('MetaSel ('Just "mainTarget") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [FilePath]) :*: S1 ('MetaSel ('Just "watches") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Watch]))))) |
A Watch
is used to keep targets up-to-date when source files change.
Instances
Generic Watch # | |
FromDhall Watch # | |
Defined in Milkshake.Data | |
type Rep Watch # | |
Defined in Milkshake.Data type Rep Watch = D1 ('MetaData "Watch" "Milkshake.Data" "milkshake-0.1.0.0-inplace" 'False) (C1 ('MetaCons "Watch" 'PrefixI 'True) (S1 ('MetaSel ('Just "paths") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Text]) :*: S1 ('MetaSel ('Just "target") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Target))) |