Execute an expression for each record to generate new records.
recs generate [options] <expression> [files...]Execute an expression for each record to generate new records. The expression should return an array of new record objects (or a single record). Each generated record gets a chain link back to the original input record under the '_chain' key (configurable via --keychain).
| Flag | Description |
|---|---|
--keychain <name> |
Key name for the chain link back to the original record. Default is '_chain'. May be a key spec. |
--passthrough |
Emit the input record in addition to the generated records. |
recs generate 'fetchFeed(r.url).map(item => ({ title: item.title }))'