From bdd970fe719f78ba0b13446190ede748e3f8fb4d Mon Sep 17 00:00:00 2001
From: Laurent Bercot
Date: Sat, 18 Jun 2016 18:11:53 +0000
Subject: Revert backtick to a non-wrapper; add -I to backtick and withstdinas
---
doc/backtick.html | 27 +++++++++++++++++----------
doc/withstdinas.html | 27 +++++++++++++++++----------
2 files changed, 34 insertions(+), 20 deletions(-)
(limited to 'doc')
diff --git a/doc/backtick.html b/doc/backtick.html
index 6aa2f01..694a29d 100644
--- a/doc/backtick.html
+++ b/doc/backtick.html
@@ -46,20 +46,27 @@ output as a value.
Options
- - -i : insist. If prog1 crashes or exits non-zero,
-backtick exits with an
-approximation of the same exit code.
- - -D default : default value. If
-prog1 crashes or exits non-zero, default is used as
-variable's value. If neither the -i nor the -D
-option have been given, backtick execs into
-prog2... no matter what prog1 does, with the null word as
-variable's value if prog1 didn't write anything before
-dying.
- -n : chomp an ending newline off prog1...'s
output.
+
+ The other options tell backtick what to do if prog1...'s output
+is not suitable as the contents of an environment variable, i.e. it
+contains a null character:
+
+
+
+ - -i : backtick exits 1.
+ - -I : variable is removed from
+the environment, and execution proceeds.
+ - -D default : the value of variable
+is set to default, and execution proceeds.
+ - neither of those options: the value of variable is set to whatever
+the start of prog1...'s output is, up to the first null character;
+then execution proceeds.
+
+
Notes
diff --git a/doc/withstdinas.html b/doc/withstdinas.html
index 29ad1b6..db49681 100644
--- a/doc/withstdinas.html
+++ b/doc/withstdinas.html
@@ -31,7 +31,7 @@ environment variable.
- withstdinas [ -i | -D default ] [ -n ] variable prog...
+ withstdinas [ -i | -I | -D default ] [ -n ] variable prog...
@@ -44,18 +44,25 @@ environment variable.
Options
- - -i : insist. If the data on stdin is invalid as
-an environment variable, for instance if it contains a null
-character, withstdinas exits 1.
- - -D default : default value.
-If the data on stdin is invalid, default is used as
-variable's value. If neither the -i nor the -D
-option have been given, withstdinas execs into
-prog... with variable containing whatever value could be read on stdin,
-cut before the first null character.
- -n : chomp an ending newline off stdin.
+
+ The other options tell withstdinas what to do if its input is
+not suitable as the contents of an environment variable, i.e. it
+contains a null character:
+
+
+
+ - -i : withstdinas exits 1.
+ - -I : variable is removed from
+the environment, and execution proceeds.
+ - -D default : the value of variable
+is set to default, and execution proceeds.
+ - neither of those options: the value of variable is set to whatever the
+start of the input is, up to the first null character; and execution proceeds.
+
+
Notes