This week's book giveaway is in the Big Data forum.
We're giving away four copies of Elasticsearch in Action and have Radu Gheorghe & Matthew Lee Hinman on-line!
See this thread for details.
The moose likes Linux / UNIX and the fly likes Shell script running jar file Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Elasticsearch in Action this week in the Big Data forum!
JavaRanch » Java Forums » Engineering » Linux / UNIX
Bookmark "Shell script running jar file" Watch "Shell script running jar file" New topic
Author

Shell script running jar file

Patricia Samuel
Ranch Hand

Joined: Sep 12, 2007
Posts: 300
Hi Folks,

When i try run a jar file from shell script , i face some prob.

I have given this command in shell file - java -jar proc.jar arg1.arg1 arg2.arg2 arg3.agr3

My main class takes three argument. But somehow shell file is not taking arg3 in consideration. This command works well when i run it straight away at $ but shows some problem in shell script.

Any suggestion.

Regards,
Patricia Samuel

Patricia Samuel
Ranch Hand

Joined: Sep 12, 2007
Posts: 300
Resolved. Last parameter in the script was having space and when property tries to load it, it does not find the value.

Thanks Anyways!!!
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Shell script running jar file