I have a master shell, which calls another shell to export some env variables. But when I just run the child shell from the command line, and see if the variables are exported by doing,
echo $EXPORTED_VAR1
I am not seeing the value.
But I am sure, I am using the child shell from a master... (4 Replies)
hi i want to write a shell script to set environment variables . But i am not been able to set that for the current shell instead i have to spawn a new shell. Is there a way to set the env variable for the current shell using shell script in bash shell ?
Thnx (2 Replies)
Hi,
I am a newbie to unix as well as scripting. I need to write a script, which on execution sets the necessay oracle variables.
Can someone help me out as to how to proceed? also can u suggest good tutorial for bash/shell scripting?
thanks (1 Reply)
Hello everybody,
I am having problem in converting byte array variables to Hexa String variables for Linux. I have done, converting byte array variables to Hexa String variables for Windows but same function doesn't work for linux. Is there any difference in OS ? The code for Windows is given... (2 Replies)
Hi !
How to export ENV variables, which remains set for all the shell
Example :-
Login :myID
Pwd : **** -> Here my ID .profile is executed. Let say I set MYENV variable
Kisses% rlogin ABC -l XXXGroupID -> I login into a remote Solaris Server ABC
password : **** -> "XXXGroupID's... (1 Reply)
Hi all guys,
how you can read in thread title, I'm deploying a bash script in which I have to export some variables inside it.
But (I think you know) the export command works only inside the script and so, on exit command, the variables aren't set like I set inside the script.
Consequently in... (8 Replies)
I need to export the built in awk variables for columns so that they are available for the rest of the script. This is what I have so far:
cat /tmp/test | eval `awk '{print "export NAME="$1; print "export NAME2="$2;}'`
echo Host is "$NAME" and Host2 is "$NAME2"
When I run bash -x to... (2 Replies)
Hi
I want to read variables from one file and then set it as environment variable;
The text file is test.txt which contains
SPEED:1000
IP:172.26.126.11
My code is:
while read line; do
var1=`echo $line | awk 'BEGIN {FS=":"} { print $1 }'`
echo $var1
var2=`echo $line | awk 'BEGIN {FS=":"}... (8 Replies)
So i have a script that is like this:
#!/bin/sh
VARA="elementary 1
elementary 2
nursery A
nursery B
highschool AZ"
echo "${ContentOfADifferentSCRIPT}" | sh
i do not have control over the script that is inside the variable "${ContentOfADifferentSCRIPT}".
however, i know that the... (3 Replies)