10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello all,
How can I invoke the bash shell (via command line) to execute another command by setting an exported environmental variable on the fly (as this env var would be used by the command -another script, the bash would execute).
This needs to be done in one single line as the same would... (4 Replies)
Discussion started by: Praveen_218
4 Replies
2. Shell Programming and Scripting
Hello
I have found some piece of code to verify and then run shell script with root permission from normal user.
see : http://blog.mecworks.com/articles/2006/02/23/bash-scripting-tip-running-a-script-as-root
I have wrote two scripts using this tips.
- one to copy file from server to local... (6 Replies)
Discussion started by: jcdole
6 Replies
3. Shell Programming and Scripting
greetings,
i have the following env variable:
LSB_HOSTS='t70cra102 t70cra102 t70cra108 t70cra108'the variable could be any number of host names and sometimes the same name several times. i was hoping there's a way to turn it into the following:
NEW_LSB_HOSTS=,,,]always appreciate the help... (2 Replies)
Discussion started by: crimso
2 Replies
4. UNIX for Advanced & Expert Users
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)
Discussion started by: idro
8 Replies
5. Solaris
Hi
I'm trying to understand variable scopes in solaris10.
It is said that to display env variables we use 3 commands :
- env
- set
- export
What is the difference between them ?
thx for help.
---------- Post updated at 11:00 AM ---------- Previous update was at 10:50 AM ----------
... (2 Replies)
Discussion started by: presul
2 Replies
6. Shell Programming and Scripting
Hi,
I have two scripts say one.sh and two.sh.
I want one.sh to continuously export a variable in loop. and when two.sh starts then it should read the last value exported from one.sh.
file: one.sh
#! bin/sh
for i in `seq 1 1 4000000`; do
export VAR=$(($i**$i)) ;
done
file two.sh
... (2 Replies)
Discussion started by: bhushan123
2 Replies
7. Shell Programming and Scripting
I have a shell script I want to run that will set environment variables based on the value of an input variable submitted when the shell script is called. For example:
$ mgenv.sh prod
This would set environment variables for prod
$ mgenv.sh test
This would set environment variables... (1 Reply)
Discussion started by: brtaylor73
1 Replies
8. UNIX for Advanced & Expert Users
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)
Discussion started by: dashok.83
1 Replies
9. Shell Programming and Scripting
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)
Discussion started by: varun.81
2 Replies
10. Shell Programming and Scripting
Hi all,
I have seen it in all the .profile files and env file this
PATH=/usr/bin:/etc:/usr/sbin:/usr/ucb:$HOME/bin:/usr/bin/X11:/sbin:.
export PATH
What exactly does this Export path does??
Thanks
SUmeet (1 Reply)
Discussion started by: sumeet
1 Replies