úÎ!C6?Ê:      !"#$%&'()*+,-./0123456789Safe8=?HV í command-qq+Embed haskell values into external commandsI recommend using -XExtendedDefaultRuleso for modules where you want to embed values, it would save for annoying type annotations for numeric literals embed . embed = embed  command-qqembed ("hi" :: Text.Lazy.Text)"hi" command-qqembed ("hi" :: Text.Text)"hi" command-qqembed ("hi" :: String)"hi" command-qq embed 'c'"c" command-qq embed (3 % 5)"0.6"Safe=?HV/" command-qq3Different interesting return types for quasiquoters6Instances here mostly resemble the types of things in System.Process$ command-qqPReturn exit code, stdout, and stderr of the external process and pass supplied : to its stdin?[sh|while read line; do echo ${#line}; done|] "hello\nworld!\n"(ExitSuccess,"5\n6\n","")% command-qq8Return exit code, stdout, and stderr of external processO[sh|echo hello world; echo bye world >&2; exit 1|] :: IO (ExitCode, Text, Text)-(ExitFailure 1,"hello world\n","bye world\n")& command-qq%Return stdout of external process as ;9Does not care whether external process has failed or not.&[sh|echo -n hello world|] :: IO String "hello world"' command-qq)Return stdout of the external process as :9Does not care whether external process has failed or not.$[sh|echo -n hello world|] :: IO Text "hello world"( command-qq(Return exit code of the external processh|exit 0|] :: IO ExitCode ExitSuccessh|exit 7|] :: IO ExitCode ExitFailure 7) command-qqQThe most basic instance: nothing is known about what happened in external commandRExternal command's stdout and stderr go to caller's stdout and stderr respectively[sh|echo hello world|] :: IO () hello world"#"#None %=?HV:ò * command-qq!Quasiquoter for the default shell&Constructs polymorphic action of type  Eval a => a from passed string.Uses SHELL6 environment variable as path to shell executable or /bin/sh if it is unset.)[sh|echo "hello, world!"|] :: IO ExitCode ExitSuccess%[sh|echo "hello, world!"|] :: IO Text"hello, world!\n"5Haskell values can be embedded with Ruby-like syntax:let apples = 7)[sh|echo "#{apples} apples!"|] :: IO Text "7 apples!\n"+ command-qq(Simple quasiquoter for the default shell*2 analog that always constructs an action of type IO ()3 and so can always be used without type annotationsh_|echo "hello, world!"|] hello, world!, command-qqShell's quasiquoter constructor9"Shell" here means executable that has the following API: <SHELL> -c <COMMAND> e.g. sh, bash, zsh, ksh, tcsh, python, etc- command-qq%Interpreter's quasiquoter constructor?"Interpreter" here means executable that has the following API: <INTERPRETER> -e <COMMAND> e.g. perl, ruby, ghc, etc. command-qqXConstruct quasiquoter from function taking the string and producing Haskell expression.eOther kinds of quasiquoters (patterns, types or declarations quasiquoters) will fail at compile time/ command-qq6Construct Haskell expression for external command call< command-qq6Construct Haskell expression for external command call0 command-qq‚Construct Haskell expression from the string, substituting variables for their values. Variable expansion uses a ruby-like syntax= command-qq7Get environment variable or default value if it's unset/ command-qq Command path command-qq8Arguments that go to command before quasiquoter contents command-qqQuasiquoter contents< command-qq Command path command-qq8Arguments that go to command before quasiquoter contents command-qqQuasiquoter contents= command-qqThe default vefault command-qqEnvironment variable "#*+,-./0+*,-./0None?~ 1 command-qqbash shell2 command-qqzsh shell3 command-qqawk interpreter4 command-qqghci interpreter5 command-qqperl interpreter6 command-qqruby interpreter7 command-qqpython interpreter8 command-qqpython2 interpreter9 command-qqpython3 interpreter 123456789 123456789>      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFG)command-qq-0.3.1.0-Hr96UWZDh16998JwRyVoorSystem.Command.QQ.EmbedSystem.Command.QQ.EvalSystem.Command.QQSystem.Command.QQ.PredefEmbedembed $fEmbedText $fEmbedText0 $fEmbed[] $fEmbedChar $fEmbedRatio$fEmbedCDouble $fEmbedCFloat$fEmbedCULLong $fEmbedCLLong $fEmbedCSize $fEmbedCULong $fEmbedCLong $fEmbedCUInt $fEmbedCInt$fEmbedCUShort $fEmbedCShort $fEmbedCUChar $fEmbedCSChar $fEmbedCChar $fEmbedDouble $fEmbedFloat $fEmbedWord64 $fEmbedWord32 $fEmbedWord16 $fEmbedWord8 $fEmbedWord $fEmbedInt64 $fEmbedInt32 $fEmbedInt16 $fEmbedInt8 $fEmbedInt$fEmbedIntegerEvaleval$fEval->$fEvalIO $fEvalIO0 $fEvalIO1 $fEvalIO2 $fEvalIO3shsh_shell interpreterquoter callCommandsubstituteVarsbashzshawkghciperlrubypythonpython2python3 text-1.2.3.1Data.Text.Internal.LazyTextbaseGHC.BaseString callCommand_ getEnvDefault