commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ashika Umanga Umagiliya <auma...@biggjapan.com>
Subject Commons CLI : Executing from shell script ?
Date Thu, 19 Nov 2009 10:21:29 GMT
Greetings all,

In my application I have used Commons CLI to parse command line arguments.
I want to run my JAR file using shell script because , I have to setup 
some environment variables.
But it seems that shell script messing around with argument order/number.

My shell script is as follows:


export ARCH=lx24-amd64
export SGE_ROOT=/SGE6/sge6.2
export LD_LIBRARY_PATH=$SGE_ROOT/lib/$ARCH/
#echo $SGE_ROOT
#echo $LD_LIBRARY_PATH
java -jar analyse.jar $1 $2 $3 $4 $5 $6 $7 $8 $9 $10 $11 $12 $13 $14 $15 
$16 $17 $18 $19 $20


But  when I run directly from shell using "java -jar analyse.jar ..... " 
everything works fine.

Any tips?

Thanks in advance.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
For additional commands, e-mail: user-help@commons.apache.org


Mime
View raw message