string split: add --allow-empty flag to be used with --fields

This commit is contained in:
Jason Nader
2020-04-18 15:25:08 +09:00
committed by Johannes Altmanninger
parent f66285d7a1
commit 6a839519b9
2 changed files with 29 additions and 5 deletions

View File

@@ -111,6 +111,9 @@ string split -f1 ' ' 'a b' 'c d'
# CHECK: a
# CHECK: c
string split --allow-empty --fields=2,9 "" abc
# CHECK: b
seq 3 | string join ...
# CHECK: 1...2...3