Hi supareno,

I'm trying not to have to manipulate the manifest by hand. It is generated
by the maven-jar-plugin and contains all the dependencies I need. I also
need to be able to speficy where the properties files are located for each
target platform. I posted my own solution to this.

Thanks for your reply,

Alex


supareno wrote:
> 
> alexworden ,
> 
> 
> did you add this to your manifest:
> 
> Class-Path: foo.jar bar.jar
> 
> and is your folder looks like this:
> 
> <appfolder>
>     |_ myExecJar.jar
>     |_ foo.jar
>     |_ bar.jar
> 
> ??
> 
> check out this
> 
> http://java.sun.com/docs/books/tutorial/deployment/jar/downman.html
> 
> it may help you
>> Hi,
>>
>> I have a standalone application that needs to be run on a production
>> machine. I'm using the maven assembly plugin to create a zip file that
>> contains all of the dependencies. So far so good, however, I need a
>> script
>> that can be invoked on the production machine (from a cron job). 
>>
>> I can write this script myself, but I'll need to ensure that all the
>> dependency jars are included in the classpath. I'm hoping that the
>> assembly
>> plugin or some other maven feature will help me achieve this last crucial
>> phase but I can't find any documentation or a single example. 
>>
>> I have persuaded Maven to create an executable jar of my project and it
>> appears to have put all the dependencies in the Manifest file. When I
>> invoke
>> it using "java -jar myExecJar.jar" it does appear to find the dependent
>> jars
>> that are in the same "lib" directory as myExecJar.jar (I have no idea
>> why). 
>> My problem is that I need to specify an additional path to my classpath
>> that
>> contains some properties files for the target platform. If I use the
>> -classpath, I can no-longer invoke my executable jar. I've tried just
>> setting CLASSPATH but this has no effect. 
>>
>> Can anyone help please?
>>
>> Thanks,
>>
>> Alex
>>
>>   
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Packaging-an-application-that-can-be-run-tp20016263p20023051.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to