• Post Reply Bookmark Topic Watch Topic
  • New Topic

dout in jar command plz hepl me

 
kalai sundar
Ranch Hand
Posts: 69
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
my problem is i am creating jar file using java code, using the RuntimeClass, my code is
Runtime.getRuntime().exec("jar -cvf " +JNam +" "+metaNam+" " +ejbNam +" "+ remNam+" " + homNam);

here JNam is my jar file name myjarfile.jar
metaNam is my MEATA-INF Folder, which contain 2 files ejb.xml and jboss.xml.
ejbNam is my bean name for eg bean.class
remNam is my remote name for eg remote.class
homNam is my home name for eg home.class

my problem here is, when i execute this command "myjarfile" jar file si created, and automatic META-INF folder is created, in that MANIFEST is there, i want my 2 files ejb.xml and jboss.xml in metaNam should be replaced to automatic MEAT-INF FOILDER.vat i am geting is automatic META-INF folder plus my META_INF folder as seperate, i don't want like that, i want my 2 xml files to be replaced to autimatically created META_INF.vat commnad i should use. hepl me


kalai
 
Nadeem Awad
Ranch Hand
Posts: 74
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear kalai,
I think you should consider using the JDK Jar utility, which comes in the java.util.jar package. Below is a sample code that shows how to use it.



HTH.

[ July 12, 2005: Message edited by: Nadeem Awad ]
[ July 12, 2005: Message edited by: Nadeem Awad ]
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!