HomeFreeBSD

seq(1): Put separator only between the elements.

Description

seq(1): Put separator only between the elements.

  • Using non-default ('\n') separator will produce an output with the separator at the end of the output, eg.

% echo "[$(seq -s ' ' 0 2)]"
[0 1 2 ]

  • The output should always be followed by a new line character. Currently:

% seq -s ' ' 0 2
0 1 2 %

This change makes seq(1) to behave the same way Linux seq(1):

% echo "[$(seq -s ' ' 0 2)]"
[0 1 2]

% seq -s ' ' 0 2
0 1 2
%

Approved by: oshogbo
Differential Revision: https://reviews.freebsd.org/D43094

Details

Provenance
pjdAuthored on Dec 19 2023, 2:39 AM
Differential Revision
D43094: seq(1): Put separator only between the elements.
Parents
rG8f7ed58a1555: regex: mixed sets are misidentified as singletons
Branches
Unknown
Tags
Unknown