giml-compiler-0.1.0.0: A Giml->JavaScript compiler
Safe HaskellSafe-Inferred
LanguageGHC2021

Language.Giml.Compiler.Run

Description

Command-line interface for gimlc

Synopsis

Documentation

data Command w Source #

gimlc cli interface type

Constructors

Compile 

Fields

Parse 

Fields

Infer 

Fields

Interactive 

Fields

Instances

Instances details
Generic (Command w) Source # 
Instance details

Defined in Language.Giml.Compiler.Run

Associated Types

type Rep (Command w) :: Type -> Type #

Methods

from :: Command w -> Rep (Command w) x #

to :: Rep (Command w) x -> Command w #

Show (Command Unwrapped) Source # 
Instance details

Defined in Language.Giml.Compiler.Run

ParseRecord (Command Wrapped) Source # 
Instance details

Defined in Language.Giml.Compiler.Run

type Rep (Command w) Source # 
Instance details

Defined in Language.Giml.Compiler.Run

type Rep (Command w) = D1 ('MetaData "Command" "Language.Giml.Compiler.Run" "giml-compiler-0.1.0.0-IJsukKXzTkdIZf4sJi4djn" 'False) ((C1 ('MetaCons "Compile" 'PrefixI 'True) (S1 ('MetaSel ('Just "input") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (w ::: (FilePath <?> "input file"))) :*: (S1 ('MetaSel ('Just "output") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (w ::: (Maybe FilePath <?> "output file"))) :*: S1 ('MetaSel ('Just "warn") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (w ::: (Bool <?> "emit warnings"))))) :+: C1 ('MetaCons "Parse" 'PrefixI 'True) (S1 ('MetaSel ('Just "input") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (w ::: (FilePath <?> "input file"))) :*: S1 ('MetaSel ('Just "output") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (w ::: (Maybe FilePath <?> "output file"))))) :+: (C1 ('MetaCons "Infer" 'PrefixI 'True) (S1 ('MetaSel ('Just "input") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (w ::: (FilePath <?> "input file"))) :*: (S1 ('MetaSel ('Just "output") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (w ::: (Maybe FilePath <?> "output file"))) :*: S1 ('MetaSel ('Just "warn") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (w ::: (Bool <?> "emit warnings"))))) :+: C1 ('MetaCons "Interactive" 'PrefixI 'True) (S1 ('MetaSel ('Just "load") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (w ::: (Maybe FilePath <?> "input file"))))))

run :: IO () Source #

Reads command-line arguments and acts accordingly

process :: (FilePath -> Text -> IO (Either Text Text)) -> FilePath -> Maybe FilePath -> IO () Source #

Takes a processing function, an input file and optionally an output file