bash-0.0.0: Bash generation library.



Shortcuts for Bash generation that also demonstrate use of the library.



cmd :: Expression t -> [Expression t] -> Statement tSource

Create a simple command from expressions.

esed :: Monoid m => Identifier -> Bool -> Annotated mSource

Declare or assign an array to a sed command line that will use extended regular expressions, checking for GNU or BSD sed. The Bool argument determines whether to insert the declaration or not.

for :: (Monoid m, Integral i) => Identifier -> i -> i -> Annotated m -> Statement mSource

Perform a statement for integer values ranging from the first integral parameter to the second, using seq.

seqAZ :: Integral i => i -> i -> Statement tSource

Evaluate seq for the given arguments.

setSafe :: Statement tSource

A set statement that covers a few error handling options, setting errexit, nounset and pipefail.

ann_ :: Monoid m => Statement m -> Annotated mSource

Annotate a statement with the 0 value of a monoid.