ENVSUBST(1) GNU ENVSUBST(1)NAME
envsubst - substitutes environment variables in shell format strings
SYNOPSIS
envsubst [OPTION] [SHELL-FORMAT]
DESCRIPTION
Substitutes the values of environment variables.
Operation mode:
-v, --variables
output the variables occurring in SHELL-FORMAT
Informative output:
-h, --help
display this help and exit
-V, --version
output version information and exit
In normal operation mode, standard input is copied to standard output, with references to environment variables of the form $VARIABLE or
${VARIABLE} being replaced with the corresponding values. If a SHELL-FORMAT is given, only those environment variables that are referenced
in SHELL-FORMAT are substituted; otherwise all environment variables references occurring in standard input are substituted.
When --variables is used, standard input is ignored, and the output consists of the environment variables that are referenced in SHELL-FOR-
MAT, one per line.
AUTHOR
Written by Bruno Haible.
REPORTING BUGS
Report bugs to <bug-gnu-gettext@gnu.org>.
COPYRIGHT
Copyright (C) 2003-2007 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.
SEE ALSO
The full documentation for envsubst is maintained as a Texinfo manual. If the info and envsubst programs are properly installed at your
site, the command
info envsubst
should give you access to the complete manual.
GNU gettext-runtime 0.17 November 2007 ENVSUBST(1)
Check Out this Related Man Page
ENVSUBST(1) GNU ENVSUBST(1)NAME
envsubst - substitutes environment variables in shell format strings
SYNOPSIS
envsubst [OPTION] [SHELL-FORMAT]
DESCRIPTION
Substitutes the values of environment variables.
Operation mode:
-v, --variables
output the variables occurring in SHELL-FORMAT
Informative output:
-h, --help
display this help and exit
-V, --version
output version information and exit
In normal operation mode, standard input is copied to standard output, with references to environment variables of the form $VARIABLE or
${VARIABLE} being replaced with the corresponding values. If a SHELL-FORMAT is given, only those environment variables that are referenced
in SHELL-FORMAT are substituted; otherwise all environment variables references occurring in standard input are substituted.
When --variables is used, standard input is ignored, and the output consists of the environment variables that are referenced in SHELL-FOR-
MAT, one per line.
AUTHOR
Written by Bruno Haible.
REPORTING BUGS
Report bugs to <bug-gnu-gettext@gnu.org>.
COPYRIGHT
Copyright (C) 2003-2007 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.
SEE ALSO
The full documentation for envsubst is maintained as a Texinfo manual. If the info and envsubst programs are properly installed at your
site, the command
info envsubst
should give you access to the complete manual.
GNU gettext-runtime 0.18.1 June 2010 ENVSUBST(1)
hi, this echo $SHELL will give the shell name.. how to get the other list of variables (besides SHELL) values?
and also, different shells have different variable names (example SHELL) (10 Replies)
Hi,
I have some problem in assigning values to variables: This is what Iam literally doing:
i=0
input=test
temp$i = $input
In the sense, I try to assign the value in the variable input (ie., test) to another variable temp0 (since i is assigned 0, temp$i is temp0). Seems simple, but I get... (3 Replies)
Hai friends , I am Beginer to unix, Please tell me what is the Shell used in HP-UX (Most used)? And are there any versions of that SHELL?
And please tell me How can i get the directories listing(Excluding) files? (1 Reply)
Hi all,
here is a problem,
i am having a data in a file of this format,
cat filename|grep -ivn edc|tr -s ' ' +|cut -d+ f1,12
1 01:18:38 2007
25 01:43:38 2007
48 01:58:45 2007
71 02:11:02 2007
102 02:19:51 2007
and so on ........ ....... .
here... (4 Replies)
Hi,
I need to write a sed that replaces the value of all environment variables that have PASS in the name with ***** . I have a log file who prints the value of all environment variables ,including those who hold passwords. In the name of these variables I found always the PASS string, ex:... (16 Replies)
i am asking to do somethings like:
make use of 2 environment variables:
ASS1_DATA_DIR specifies the location of the input data files
ASS1_OUTPUT_DIR specifies the location of the output data files
i have something like that;
#set environment variables
set
VARIABLE1=ASS1_DATA_DIR... (5 Replies)
Hi All,
I have 2 variables like SDATE and EDATE.
Now for example i ll give you values for the above 2 variables.
SDATE=11/08/09 11:22
EDATE=11/09/09 22:33
the values of the above variables are represented like this>>>>>> mm/dd/yy hh:mm Now I want to evaluate total time elapsed... (3 Replies)
i have two machines that should be identical but on one system there are some oracle environment (ORACLE_SID, ORACLE_HOME, etc...) variables that are not being set for the users.
I am trying to find where those environment variables are being set on the system which is working properly. All... (5 Replies)
We all know environment variables.But when I type "set" in bash shell, I found not only environment variables but also this:
_alias ()
{
local cur;
COMPREPLY=();
cur=${COMP_WORDS};
case "$COMP_LINE" in
*)
COMPREPLY=($( compgen -A alias -S '=' -- $cur... (2 Replies)
KINDLY HELP ME FOR SHELL SCRIPTING FOR THIS TASK.
My input file consists of thousands of sequence in this format. The given input file consists of four sequences which are starting with ‘>’ symbol (each sequence shown in different colour for easy understanding). I have to use a command at $... (3 Replies)
Hi,
I have an issue that hope someone will be able to help me with....
I'm using a while-read loop to read lines from a file that contain variables, and I want the variables substituted, but I can't get it to work - the below example with explain:
while read line
do
echo $line
... (5 Replies)
I am completely new to Shell scripting and I have almost no idea what I'm doing here. I'm not a stranger at all to programming, but the way SHELL is done drives me to insanity. Here's my current issue:
1. We are to create a BASH script called rafactor.sh
This program takes in two (or three)... (6 Replies)
Hi, I have two variables with some values with 5 decimal digits and separated with space, the values of the variables are different, I want to make operations with this two variables.
The way was I find to do it itīs with files and
paste file1 file2 | awk '{print $1 - $2}'
I want to make it... (8 Replies)
Hi,
I have a file which has wrong time format and we want to correct it before we load it.
WRONG FORMAT : 93:0:00
CORRECT FORMAT :09:30:00
If you notice the 0 at the front is missing. Its the case always. (6 Replies)
This is not a question. Just a little note, because I've been here some time and never read about awk accessing environment variables. So here's my use case and demonstration of how to use the ENVIRON array. My operating environment is ubuntu 18.04 / docker / GNU awk 4.1.4. ENVIRON seems to posix... (2 Replies)