A command line regex multiplexer for filtering and streaming lines to multiple targets.
tail -f log.txt | remux ERROR errors.txt WARN warnings.txt INFO verbose.txtgo get -u neilpa.me/remuxThere are also pre-built static binaries for Windows, Mac and Linux on the releases tab.
remux [options] <regex0> [<file0> [<regex1> <file1> ...]]
By default, source data is streamed from STDIN, use -i to specify a file instead. The -i argument can be set more than once to read from multiple input sources serially. If interleaved input is required, send through paste first
An empty string or - can be provided to -i to explicitly use STDIN. Similarly, an empty string or - for an output file to use STDOUT. Additionally, omitting the last file argument also implies STDOUT as the target.
- Process substitution
- Explicit file descriptors
- Named pipes
peecommand inmoreutilsMULTIOSoption fromzsh