Skip to content
Myr

Mention -n in IO-section and for input/inputs

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Mattias Wadman · committed by Nico Williams · parent c4d39c4 · Browse files · 1 file+10 added−2 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+10 added−2 removed

  • other:+10 added−2 removed

1 file+10 added−2 removed

modified:docs/content/manual/manual.yml+10 added-2 removed
2922 unmodified lines
2923 form of control over when inputs are read. Two builtins functions2924 are provided for this, `input` and `inputs`, that read from the2925 same sources (e.g., `stdin`, files named on the command-line) as2926 jq itself. These two builtins, and jq's own reading actions, can2927 be interleaved with each other.2927 be interleaved with each other. They are commonly used in combination2928 with the null input option `-n` to prevent one input from being read2929 implicitly.29302931 Two builtins provide minimal output capabilities, `debug`, and2932 `stderr`. (Recall that a jq program's output values are always2933 output as JSON texts on `stdout`.) The `debug` builtin can have
11 unmodified lines
2945 body: |29462947 Outputs one new input.29482949 Note that when using `input` it is generally be necessary to2950 invoke jq with the -n command-line option, otherwise2951 the first entity will be lost.29522953 - title: "`inputs`"2954 body: |29552956 Outputs all remaining inputs, one by one.29572958 This is primarily useful for reductions over a program's2953 inputs.2959 inputs. Note that when using `inputs` it is generally necessary2960 to invoke jq with the -n command-line option, otherwise2961 the first entity will be lost.29622963 - title: "`debug`"2964 body: |2965
407 unmodified lines