aboutsummaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
Diffstat (limited to 'doc')
-rw-r--r--doc/ChangeLog9
-rw-r--r--doc/gawk.info115
-rw-r--r--doc/gawk.texi58
-rw-r--r--doc/gawktexi.in58
4 files changed, 191 insertions, 49 deletions
diff --git a/doc/ChangeLog b/doc/ChangeLog
index 06248165..494b896c 100644
--- a/doc/ChangeLog
+++ b/doc/ChangeLog
@@ -1,3 +1,12 @@
+2016-02-03 Arnold D. Robbins <arnold@skeeve.com>
+
+ * gawktexi.in (VMS Running): Improve the Texinfo usage.
+
+2016-01-31 John E. Malmberg <wb8tyw@qsl.net>
+
+ * gawktexi.in (VMS Running): Add instructions on how to redirect
+ gawk data to a VMS command.
+
2016-01-18 Arnold D. Robbins <arnold@skeeve.com>
* gawktexi.in (Bracket Expressions): Document that '[', '.' and
diff --git a/doc/gawk.info b/doc/gawk.info
index c0c44864..472b50f7 100644
--- a/doc/gawk.info
+++ b/doc/gawk.info
@@ -28697,7 +28697,7 @@ by 3 bits to make room for the severity codes.
To extract the actual 'gawk' exit code from the VMS status, use:
- unix_status = (vms_status .and. &x7f8) / 8
+ unix_status = (vms_status .and. %x7f8) / 8
A C program that uses 'exec()' to call 'gawk' will get the original
Unix-style exit value.
@@ -28720,6 +28720,46 @@ of 'AWKPATH' is a comma-separated list of directory specifications.
When defining it, the value should be quoted so that it retains a single
translation and not a multitranslation 'RMS' searchlist.
+ This restriction also applies to running 'gawk' under GNV, as
+redirection is always to a DCL command.
+
+ If you are redirecting data to a VMS command or utility, the current
+implementation requires that setting up a VMS foreign command that runs
+a command file before invoking 'gawk'. (This restriction may be removed
+in a future release of 'gawk' on VMS.)
+
+ Without this command file, the input data will also appear prepended
+to the output data.
+
+ This also allows simulating POSIX commands that are not found on VMS
+or the use of GNV utilities.
+
+ The example below is for 'gawk' redirecting data to the VMS 'sort'
+command.
+
+ $ sort = "@device:[dir]vms_gawk_sort.com"
+
+ The command file needs to be of the format in the example below.
+
+ The first line inhibits the passed input data from also showing up in
+the output. It must be in the format in the example.
+
+ The next line creates a foreign command that overrides the outer
+foreign command which prevents an infinite recursion of command files.
+
+ The next to the last command redirects 'sys$input' to be
+'sys$command', in order to pick up the data that is being redirected to
+the command.
+
+ The last line runs the actual command. It must be the last command
+as the data redirected from 'gawk' will be read when the command file
+ends.
+
+ $!'f$verify(0,0)'
+ $ sort := sort
+ $ define/user sys$input sys$command:
+ $ sort sys$input: sys$output:
+

File: gawk.info, Node: VMS GNV, Next: VMS Old Gawk, Prev: VMS Running, Up: VMS Installation
@@ -34478,6 +34518,7 @@ Index
* redirect gawk output, in debugger: Debugger Info. (line 73)
* redirection of input: Getline/File. (line 6)
* redirection of output: Redirection. (line 6)
+* redirection on VMS: VMS Running. (line 64)
* reference counting, sorting arrays: Array Sorting Functions.
(line 77)
* regexp: Regexp. (line 6)
@@ -35626,41 +35667,41 @@ Ref: VMS Compilation-Footnote-11150091
Node: VMS Dynamic Extensions1150149
Node: VMS Installation Details1151834
Node: VMS Running1154087
-Node: VMS GNV1156928
-Node: VMS Old Gawk1157663
-Node: Bugs1158134
-Node: Other Versions1162331
-Node: Installation summary1168917
-Node: Notes1169975
-Node: Compatibility Mode1170840
-Node: Additions1171622
-Node: Accessing The Source1172547
-Node: Adding Code1173983
-Node: New Ports1180202
-Node: Derived Files1184690
-Ref: Derived Files-Footnote-11190175
-Ref: Derived Files-Footnote-21190210
-Ref: Derived Files-Footnote-31190808
-Node: Future Extensions1190922
-Node: Implementation Limitations1191580
-Node: Extension Design1192763
-Node: Old Extension Problems1193917
-Ref: Old Extension Problems-Footnote-11195435
-Node: Extension New Mechanism Goals1195492
-Ref: Extension New Mechanism Goals-Footnote-11198856
-Node: Extension Other Design Decisions1199045
-Node: Extension Future Growth1201158
-Node: Old Extension Mechanism1201994
-Node: Notes summary1203757
-Node: Basic Concepts1204939
-Node: Basic High Level1205620
-Ref: figure-general-flow1205902
-Ref: figure-process-flow1206587
-Ref: Basic High Level-Footnote-11209888
-Node: Basic Data Typing1210073
-Node: Glossary1213401
-Node: Copying1245347
-Node: GNU Free Documentation License1282886
-Node: Index1308004
+Node: VMS GNV1158366
+Node: VMS Old Gawk1159101
+Node: Bugs1159572
+Node: Other Versions1163769
+Node: Installation summary1170355
+Node: Notes1171413
+Node: Compatibility Mode1172278
+Node: Additions1173060
+Node: Accessing The Source1173985
+Node: Adding Code1175421
+Node: New Ports1181640
+Node: Derived Files1186128
+Ref: Derived Files-Footnote-11191613
+Ref: Derived Files-Footnote-21191648
+Ref: Derived Files-Footnote-31192246
+Node: Future Extensions1192360
+Node: Implementation Limitations1193018
+Node: Extension Design1194201
+Node: Old Extension Problems1195355
+Ref: Old Extension Problems-Footnote-11196873
+Node: Extension New Mechanism Goals1196930
+Ref: Extension New Mechanism Goals-Footnote-11200294
+Node: Extension Other Design Decisions1200483
+Node: Extension Future Growth1202596
+Node: Old Extension Mechanism1203432
+Node: Notes summary1205195
+Node: Basic Concepts1206377
+Node: Basic High Level1207058
+Ref: figure-general-flow1207340
+Ref: figure-process-flow1208025
+Ref: Basic High Level-Footnote-11211326
+Node: Basic Data Typing1211511
+Node: Glossary1214839
+Node: Copying1246785
+Node: GNU Free Documentation License1284324
+Node: Index1309442

End Tag Table
diff --git a/doc/gawk.texi b/doc/gawk.texi
index a5b163df..06aacd3b 100644
--- a/doc/gawk.texi
+++ b/doc/gawk.texi
@@ -38790,8 +38790,8 @@ to the original shell-style interface (see the help entry for details).
One side effect of dual command-line parsing is that if there is only a
single parameter (as in the quoted string program), the command
becomes ambiguous. To work around this, the normally optional @option{--}
-flag is required to force Unix-style parsing rather than @code{DCL} parsing. If any
-other dash-type options (or multiple parameters such as @value{DF}s to
+flag is required to force Unix-style parsing rather than @code{DCL} parsing.
+If any other dash-type options (or multiple parameters such as @value{DF}s to
process) are present, there is no ambiguity and @option{--} can be omitted.
@cindex exit status, of VMS
@@ -38809,15 +38809,15 @@ added to the number shifted over by 3 bits to make room for the severity codes.
To extract the actual @command{gawk} exit code from the VMS status, use:
@example
-unix_status = (vms_status .and. &x7f8) / 8
+unix_status = (vms_status .and. %x7f8) / 8
@end example
@noindent
A C program that uses @code{exec()} to call @command{gawk} will get the original
Unix-style exit value.
-Older versions of @command{gawk} for VMS treated a Unix exit code 0 as 1, a failure
-as 2, a fatal error as 4, and passed all the other numbers through.
+Older versions of @command{gawk} for VMS treated a Unix exit code 0 as 1,
+a failure as 2, a fatal error as 4, and passed all the other numbers through.
This violated the VMS exit status coding requirements.
@cindex floating-point, VAX/VMS
@@ -38838,6 +38838,52 @@ of @env{AWKPATH} is a comma-separated list of directory specifications.
When defining it, the value should be quoted so that it retains a single
translation and not a multitranslation @code{RMS} searchlist.
+@cindex redirection on VMS
+
+This restriction also applies to running @command{gawk} under GNV,
+as redirection is always to a DCL command.
+
+If you are redirecting data to a VMS command or utility, the current
+implementation requires that setting up a VMS foreign command that runs
+a command file before invoking @command{gawk}.
+(This restriction may be removed in a future release of @command{gawk} on VMS.)
+
+Without this command file, the input data will also appear prepended
+to the output data.
+
+This also allows simulating POSIX commands that are not found on VMS or the
+use of GNV utilities.
+
+The example below is for @command{gawk} redirecting data to the VMS
+@command{sort} command.
+
+@example
+$ sort = "@@device:[dir]vms_gawk_sort.com"
+@end example
+
+The command file needs to be of the format in the example below.
+
+The first line inhibits the passed input data from also showing up in the
+output. It must be in the format in the example.
+
+The next line creates a foreign command that overrides the outer foreign
+command which prevents an infinite recursion of command files.
+
+The next to the last command redirects @code{sys$input} to be
+@code{sys$command}, in order to pick up the data that is being redirected
+to the command.
+
+The last line runs the actual command. It must be the last command as the data
+redirected from @command{gawk} will be read when the command file ends.
+
+@example
+$!'f$verify(0,0)'
+$ sort := sort
+$ define/user sys$input sys$command:
+$ sort sys$input: sys$output:
+@end example
+
+
@node VMS GNV
@appendixsubsubsec The VMS GNV Project
@@ -42769,7 +42815,7 @@ Consistency issues:
awk '{
...
}'
-
+
Do show it when showing command-line arguments, data files, etc, even
if there is no output shown.
diff --git a/doc/gawktexi.in b/doc/gawktexi.in
index 129579a6..651d2573 100644
--- a/doc/gawktexi.in
+++ b/doc/gawktexi.in
@@ -37881,8 +37881,8 @@ to the original shell-style interface (see the help entry for details).
One side effect of dual command-line parsing is that if there is only a
single parameter (as in the quoted string program), the command
becomes ambiguous. To work around this, the normally optional @option{--}
-flag is required to force Unix-style parsing rather than @code{DCL} parsing. If any
-other dash-type options (or multiple parameters such as @value{DF}s to
+flag is required to force Unix-style parsing rather than @code{DCL} parsing.
+If any other dash-type options (or multiple parameters such as @value{DF}s to
process) are present, there is no ambiguity and @option{--} can be omitted.
@cindex exit status, of VMS
@@ -37900,15 +37900,15 @@ added to the number shifted over by 3 bits to make room for the severity codes.
To extract the actual @command{gawk} exit code from the VMS status, use:
@example
-unix_status = (vms_status .and. &x7f8) / 8
+unix_status = (vms_status .and. %x7f8) / 8
@end example
@noindent
A C program that uses @code{exec()} to call @command{gawk} will get the original
Unix-style exit value.
-Older versions of @command{gawk} for VMS treated a Unix exit code 0 as 1, a failure
-as 2, a fatal error as 4, and passed all the other numbers through.
+Older versions of @command{gawk} for VMS treated a Unix exit code 0 as 1,
+a failure as 2, a fatal error as 4, and passed all the other numbers through.
This violated the VMS exit status coding requirements.
@cindex floating-point, VAX/VMS
@@ -37929,6 +37929,52 @@ of @env{AWKPATH} is a comma-separated list of directory specifications.
When defining it, the value should be quoted so that it retains a single
translation and not a multitranslation @code{RMS} searchlist.
+@cindex redirection on VMS
+
+This restriction also applies to running @command{gawk} under GNV,
+as redirection is always to a DCL command.
+
+If you are redirecting data to a VMS command or utility, the current
+implementation requires that setting up a VMS foreign command that runs
+a command file before invoking @command{gawk}.
+(This restriction may be removed in a future release of @command{gawk} on VMS.)
+
+Without this command file, the input data will also appear prepended
+to the output data.
+
+This also allows simulating POSIX commands that are not found on VMS or the
+use of GNV utilities.
+
+The example below is for @command{gawk} redirecting data to the VMS
+@command{sort} command.
+
+@example
+$ sort = "@@device:[dir]vms_gawk_sort.com"
+@end example
+
+The command file needs to be of the format in the example below.
+
+The first line inhibits the passed input data from also showing up in the
+output. It must be in the format in the example.
+
+The next line creates a foreign command that overrides the outer foreign
+command which prevents an infinite recursion of command files.
+
+The next to the last command redirects @code{sys$input} to be
+@code{sys$command}, in order to pick up the data that is being redirected
+to the command.
+
+The last line runs the actual command. It must be the last command as the data
+redirected from @command{gawk} will be read when the command file ends.
+
+@example
+$!'f$verify(0,0)'
+$ sort := sort
+$ define/user sys$input sys$command:
+$ sort sys$input: sys$output:
+@end example
+
+
@node VMS GNV
@appendixsubsubsec The VMS GNV Project
@@ -41860,7 +41906,7 @@ Consistency issues:
awk '{
...
}'
-
+
Do show it when showing command-line arguments, data files, etc, even
if there is no output shown.