.\" Automatically generated by Pandoc 2.16.2 .\" .TH "ja (1)" "" "" "" "" .hy .SH NAME .PP ja - Jacinda: data filtering, processing, reporting .SH SYNOPSIS .PP ja run src.jac -i data.txt .PP cat FILE1 FILE2 | ja `#\[lq]$0' .PP ja tc script.jac .PP ja e `11.67*1.2' .SH DESCRIPTION .PP \f[B]Jacinda\f[R] is a data stream processing language \[`a] la AWK. .SH SUBCOMMANDS .PP \f[B]run\f[R] - Run a program from file .PP \f[B]tc\f[R] - Typecheck a program .PP \f[B]e\f[R] - Evaluate an expression (without reference to a file) .SH OPTIONS .TP \f[B]-h\f[R] \f[B]--help\f[R] Display help .TP \f[B]-V\f[R] \f[B]--version\f[R] Display version information .SH LANGUAGE .SS REGEX .PP Regular expressions follow Rust\[cq]s regex library: https://docs.rs/regex/ .SS BUILTINS .PP \f[B]:i\f[R] Postfix operator: parse integer .PP \f[B]:f\f[R] Postfix operator: parse float .PP \f[B]#\f[R] Prefix operator: tally (count bytes in string) .TP \f[B],\f[R] Ternary operator: zip with (a -> b -> c) -> Stream a -> Stream b -> Stream c .TP \f[B]|\f[R] Ternary operator: fold Foldable f :=> (b -> a -> b) -> b -> f a -> b .TP \f[B]\[ha]\f[R] Ternary operator: scan (b -> a -> b) -> b -> Stream a -> Stream b .TP \f[B]\[lq]\f[R] Binary operator: map Functor f :=> a -> b -> f a -> f b .TP \f[B][:\f[R] Unary operator: const a -> b -> a .TP \f[B]#.\f[R] Binary operator: filter (a -> Bool) -> Stream a -> Stream a .TP \f[B].\f[R] Binary operator: prior (a -> a -> a) -> Stream a -> Stream a .PP \f[B]max\f[R] Maximum of two values .PP \f[B]min\f[R] Minimum of two values .PP \f[B]&\f[R] Boolean and .PP \f[B]||\f[R] Boolean or .PP \f[B]!\f[R] Prefix boolean not .PP \f[B]\[ti]\f[R] Matches regex .PP \f[B]!\[ti]\f[R] Does not match .PP \f[B]ix\f[R] Line number .TP \f[B]substr\f[R] Extract substring Str -> Int -> Int -> Str .TP \f[B]split\f[R] Split a string by regex Str -> Regex -> List Str .TP \f[B]splitc\f[R] Split a string on a single character Str -> Str -> List Str .TP \f[B]floor\f[R] Floor function Float -> Int .TP \f[B]ceil\f[R] Ceiling function Float -> Int .PP \f[B]sprintf\f[R] Convert an expression to a string using the format string .TP \f[B]option\f[R] Option eliminator b -> (a -> b) -> Option a -> b .TP \f[B]match\f[R] Str -> Regex -> Option (Int . Int) .SS SYNTAX .PP \f[B]\[ga]n\f[R] nth field .PP \f[B]$n\f[R] nth column .PP \f[B]{%}{}\f[R] Filtered stream on lines matching , defined by .PP \f[B]{}{}\f[R] Filtered stream defined by , on lines satisfying a boolean expression. .PP \f[B]{|}\f[R] Stream defined by .PP \f[B]#t\f[R] Boolean literal .PP \f[B]_n\f[R] Negative number .TP \f[B].n\f[R] Extract the nth value List a -> a .PP \f[B]->n\f[R] Get the nth element of a tuple .SH BUGS .PP Please report any bugs you may come across to https://github.com/vmchale/jacinda/issues .SS Limitations .PP Note that \f[C]Option\f[R] is not implemented as a functor. .SH COPYRIGHT .PP Copyright 2021-2022. Vanessa McHale. All Rights Reserved. .SH AUTHORS Vanessa McHale.