Search Results

Search: Posts Made By: sonaluphale
3,622
Posted By sonaluphale
Position independent Parameter passing
Hi all,
When parameters are passed to the shell script, they are dereferenced by their position. For example,
I call myTest.sh and pass two parameters param1 and param2 as following:
./myTest.sh...
27,673
Posted By sonaluphale
But this is some kind of c library function. I...
But this is some kind of c library function. I want to use this in shell script.
27,673
Posted By sonaluphale
Equivalent command for setlocal in Unix
Hi all,
Is there any command in unix equivalent to setlocal in windows.
setlocal command is really useful in restoring local environment variables in windows.
Thanks,
Sonal.
9,640
Posted By sonaluphale
(home is just a example-name , it could be...
(home is just a example-name , it could be javahome, )

Yes, I am trying to validate javahome, anthome etc in script. Workaround would be pass parameter-name and parameter-value to the function....
9,640
Posted By sonaluphale
Maybe I will give a sample script #!/bin/sh ...
Maybe I will give a sample script

#!/bin/sh
check() {
if [ ! -d ${1} ]; then
echo "${1} is not a dir"; exit 1
fi
echo dir
}
home=/u4/k
check home
...
9,640
Posted By sonaluphale
Pass by reference in shell functions
Hi all,
In windows script, passing arguments can be done in both "call by value" and
"call by reference". Refer
http://www.commandline.co.uk/lib/treeview/index.php
Can we have call by reference...
Showing results 1 to 6 of 6

 
All times are GMT -4. The time now is 10:46 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy