Skip to content

decollate

Reverse of collate: takes a single record and produces multiple records using deaggregators.

Synopsis

bash
recs decollate [options] [files...]

Description

Reverse of collate: takes a single record and produces multiple records using deaggregators. Decollate records of input into output records.

Options

FlagDescription
--deaggregator / -d <deaggregators>Deaggregator specification (colon-separated).
--only / -oOnly output deaggregated fields, excluding original record fields. Useful when you only want the expanded data, not the source record.
--list-deaggregatorsList available deaggregators and exit.

Examples

Split the 'hosts' field into individual 'host' fields

bash
recs decollate --deaggregator 'split,hosts,/\s*,\s*/,host'

Decollate and only keep deaggregated fields

bash
recs decollate --only -d 'unarray,items,,item'

See Also

Released under the MIT License.