[−][src]Crate romulus
Romulus is a text processing language similar to sed
Here is an example program which process the output of ifconfig
/^(?P<inter>[a-zA-Z0-9]+): /,/^[a-zA-Z0-9]+:/ {
/inet (?P<ip>[0-9]{1,3}(\.[0-9]{1,3}){3})/ {
print("${inter}: ${ip}")
}
/inet6 (?P<ip>[a-fA-F0-9]{0,4}(:[a-fA-F0-9]{0,4}){0,8})/ {
print("${inter}: ${ip}")
}
}
Modules
| ast | A module organizing the romulus abstract syntax tree |
| features | A module which detects what features romulus was compiled with. |
| lex | A module which extracts romulus tokens out of string content |
| lint | A module which lints a romulus program |
| runtime | A module organizing the runtime elements of a romulus program |
Macros
| color | A macro that expands to a colored output if romulus is compiled with color support |
| nl | A macro that expands to the proper line ending character sequence for operating system |
Structs
| Interpreter | The interpreter which processes lines with a romulus program |