10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi All,
I want to pass array of argument from Java to a shell script.I can use process builder api and its exec() method to call the script,but the question is how to receive the parameter in the script.
Thanks in advance
---------- Post updated at 10:00 PM ---------- Previous update was... (1 Reply)
Discussion started by: Abhijeet_Atti
1 Replies
2. Shell Programming and Scripting
Hi,
I have a requirement to work on script, it should take either of arguments.
wrote it as below.
#!/bin/bash
usage() {
echo "$0: missing argument OR invalid option !
Usage : $0 -m|-r|-d
}
while getopts mrdvh opt; do
case "$opt" in
m) monitor_flag=monitor;;... (1 Reply)
Discussion started by: ramanaraoeee
1 Replies
3. Programming
Hello all,
New to C and I'm trying to write a program which can run a unix command. Would like to have the option of giving the user the ability to enter arguments e.g for "ls" be able to run "ls -l".
I would appreciate any help.
Thanks
#include <stdio.h>
#include <unistd.h>
#include... (3 Replies)
Discussion started by: effizy
3 Replies
4. Shell Programming and Scripting
I have one working awk command line. Which taking data from the “J1202523.TXT” file and generating the “brazil.dat” file. PFB code.
awk '{ DUNS = substr($0,0,9);if ( substr($0,14,3) == "089" ) print DUNS }' J1202523.TXT > Brazil.dat
But now I want to pass two parameter as a command line argument... (4 Replies)
Discussion started by: humaemo
4 Replies
5. Shell Programming and Scripting
Hi Gurus,
I have written a script set_env.ksh to which I pass an argument and set the oracle login credentials based on the argument I pass.
The script has code as below.
ORACLE_SID=$1
DB_SCHEMA_LOGON=$DB_SCHEMA_USER/$DB_SCHEMA_PASSWORD@$ORACLE_SID; export DB_SCHEMA_LOGON;
echo... (3 Replies)
Discussion started by: Sabari Nath S
3 Replies
6. UNIX for Dummies Questions & Answers
Hi,
I am facing a problem to pass command line arguments that looks like
<script name> aa bb "cc" dd "ee"
I want to pass all 5 elements include the " (brackets). when I print the @ARGV the " disappear. I hope I explain myself
Regards,
Ziv (4 Replies)
Discussion started by: zivsegal
4 Replies
7. Shell Programming and Scripting
$$$$$ (5 Replies)
Discussion started by: asirohi
5 Replies
8. Shell Programming and Scripting
Hi,
Lets say I have a script "ss" which does this
read abc
echo $abc
read pqr
echo $pqr
Now if I want to pass and argument to only "abc" how do I do it.
If I do
echo "somevalue" | ss, it does not prompt for pqr and its value comes out as blank.
Any help is appreciated
Thanks
P (6 Replies)
Discussion started by: patjones
6 Replies
9. UNIX for Dummies Questions & Answers
i want to redirect output of one command as the command line argument of another script
for example, say i would run this command:
find . -xdev -type f -size +4096 -exec ls -al {} \;
i wan to be able to do something like:
echo +4096 | find . -xdev -type f -size ****** -exec... (3 Replies)
Discussion started by: IMTheNachoMan
3 Replies
10. Shell Programming and Scripting
Hi all,
I'm new to Shell scripting. In my shell script for Bourne shell, the script accepts a date parameter which is optional. If the value is supplied, the supplied value should be assigned to a variable. If not, the current date will be assigned to the variable. My script is like this.
#!... (9 Replies)
Discussion started by: sumesh.abraham
9 Replies