summaryrefslogtreecommitdiffstats
path: root/txr.1
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2016-09-16 20:25:38 -0700
committerKaz Kylheku <kaz@kylheku.com>2016-09-16 20:25:38 -0700
commitfbc383882377ef0e0cbed5a0fdc468f300e9526f (patch)
tree3ae9e6c8cc528e0f78d75699b71865e373184b91 /txr.1
parent1cae1fb7f1b1c2882fedfcbfb0d97015c8726cc8 (diff)
downloadtxr-fbc383882377ef0e0cbed5a0fdc468f300e9526f.tar.gz
txr-fbc383882377ef0e0cbed5a0fdc468f300e9526f.tar.bz2
txr-fbc383882377ef0e0cbed5a0fdc468f300e9526f.zip
doc: fs variable.
* txr.1: Improve some wording in the description of the awk fs variable.
Diffstat (limited to 'txr.1')
-rw-r--r--txr.122
1 files changed, 17 insertions, 5 deletions
diff --git a/txr.1 b/txr.1
index e0f0b17c..6f150245 100644
--- a/txr.1
+++ b/txr.1
@@ -37759,7 +37759,9 @@ variable is initially
If
.code fs
-is nil, then, prior to field splitting, leading and trailing
+is
+.codn nil ,
+then, prior to field splitting, leading and trailing
whitespace is trimmed from the value of
.codn rec ,
using the
@@ -37779,9 +37781,9 @@ is zero.
If
.code fs
-is nil, then
-In this special case, the splitting is performed using
-the regular expression
+is nil, then the splitting into fields is performed as if
+the variable held the regular expression
+.codn "/[\en\et ]+/" .
This means that, by default, fields are separated by one or more consecutive
whitespace characters, which can be any mixture of spaces, tabs or newlines.
Newlines are included because they can occur in a record when the value of the
@@ -37789,6 +37791,16 @@ record separator
.code rs
is customized.
+If
+.code fs
+is not
+.codn nil ,
+it must specify a string, or a regular expression.
+A string value of
+.code fs
+denotes an exact match for that string; it isn't treated
+as a regular expression.
+
When a record is not empty,
matches for the
.code fs
@@ -37797,7 +37809,7 @@ the fields are the possibly empty non-matching parts between the matches.
If
.code fs
-is not found in the record, then the entire record is taken as a single
+is not found in the record, then the entire record is taken as a one
field.
If