summaryrefslogtreecommitdiffstats
path: root/jq.1.prebuilt
diff options
context:
space:
mode:
Diffstat (limited to 'jq.1.prebuilt')
-rw-r--r--jq.1.prebuilt24
1 files changed, 24 insertions, 0 deletions
diff --git a/jq.1.prebuilt b/jq.1.prebuilt
index 32221515..efa5aa2f 100644
--- a/jq.1.prebuilt
+++ b/jq.1.prebuilt
@@ -1930,6 +1930,30 @@ jq \'[\.[]|rtrimstr("foo")]\'
.
.IP "" 0
.
+.SS "trim, ltrim, rtrim"
+\fBtrim\fR trims both leading and trailing whitespace\.
+.
+.P
+\fBltrim\fR trims only leading (left side) whitespace\.
+.
+.P
+\fBrtrim\fR trims only trailing (right side) whitespace\.
+.
+.P
+Whitespace characters are the usual \fB" "\fR, \fB"\en"\fR \fB"\et"\fR, \fB"\er"\fR and also all characters in the Unicode character database with the whitespace property\. Note that what considers whitespace might change in the future\.
+.
+.IP "" 4
+.
+.nf
+
+jq \'trim, ltrim, rtrim\'
+ " abc "
+=> "abc", "abc ", " abc"
+.
+.fi
+.
+.IP "" 0
+.
.SS "explode"
Converts an input string into an array of the string\'s codepoint numbers\.
.