Combinar 2 Jar en 1 solo

lunes, julio 20, 2009
Esto lo encontré en un foro, sirve para combinar 2 archivos jar en uno solo, lo que sería útil para no tener que moverlos siempre en conjunto.
En una carpeta hay que crear:
- una carpeta lib, donde ponemos los jars a juntar
- una carpeta temp, la que dejamos vacía
- un archivo llamado build.xml


En el archivo build.xml ponemos lo siguiente:

<project basedir="." default="combine.jar" name="jar combiner">
<property name="base.dir" value="." />
<property name="lib.dir" value="${base.dir}/lib" />
<property name="jar.filename" value="test.jar" />
<property name="project.java_version" value="1.5" />
<property name="temp.dir" value="${base.dir}/temp" />
<target name="unjar.jar">
<unjar dest="${temp.dir}">
<patternset>
<include name="**/*.class" />
</patternset>
<fileset dir="${lib.dir}">
<include name="**/*.jar" />
</fileset>
</unjar>
</target>
<target name="combine.jar" depends="unjar.jar">
<jar jarfile="${base.dir}/${jar.filename}"
basedir="${temp.dir}" includes="**/*.class" update="true"
compress="false">
</jar>
<delete dir="${temp.dir}" quiet="true" />
</target>
</project>

Luego en línea de comandos no ubicamos en el directorio que contiene todo esto y ejecutamos el siguiente comando (es necesario tener Ant):

ant combine.jar

y con eso ya tenemos el jar conteniendo los de la carpeta lib.

211 comentarios:

«El más antiguo   ‹Más antiguo   201 – 211 de 211   Más reciente›   El más reciente»
Anónimo at: 13 de mayo de 2013, 18:33 dijo...

Excellent blog! Do you have any recommendations for aspiring writers?
I'm planning to start my own site soon but I'm a little lost on everything.

Would you advise starting with a free platform like Wordpress or
go for a paid option? There are so many choices out there that
I'm totally confused .. Any tips? Thank you!

my web-site; subtitling

Anónimo at: 13 de mayo de 2013, 19:34 dijo...

Howdy! I simply want to give you a huge thumbs up for the excellent information you have got here on this post.
I am returning to your blog for more soon.

Here is my blog ... lobstick

Anónimo at: 14 de mayo de 2013, 5:39 dijo...

Great post. I used to be checking constantly this weblog and I'm inspired! Very useful info specifically the closing part :) I maintain such info much. I used to be seeking this particular info for a long time. Thank you and best of luck.

Here is my weblog: inchelium

Anónimo at: 16 de mayo de 2013, 4:38 dijo...

The Roku when you first start it up after connecting it to the internet and your TV or monitor has several
channels but each one is only a few clicks away to install and over the internet the installation is
very easy using an account. Loading time from screen to screen can vary and at times seems like it may take
longer than usual but overall performance is great. Key issues
appear to be with wireless connection going in and out.

Also visit my blog post; roku reviews

Anónimo at: 19 de mayo de 2013, 6:13 dijo...

Now you do not use any ribbon. Prince Charles last night launched what is
believed to be a standard size and shape of diverse marks in the business advertisement is not new.
An Obama victory has many worried that rampant money stickers johannesburg will not be required to go naked
on stage for the Christmas dinner or holiday celebrations with removable vinyl wall stickers johannesburg.


My web page ... stickers hot topic

Anónimo at: 21 de mayo de 2013, 9:52 dijo...

I'm curious to find out what blog system you're working with?
I'm having some minor security problems with my latest blog and I would like to find something more safeguarded. Do you have any suggestions?

Look into my blog post :: http://clickbank-tribune.com/index.php?do=/profile-32714/info/

Anónimo at: 21 de mayo de 2013, 16:14 dijo...

I think this is among the most vital info for
me. And i am glad reading your article. But wanna remark on
some general things, The web site style is wonderful, the articles is really great : D.
Good job, cheers

Here is my weblog; http://www.goolloo.com/profile-49207/info/

Anónimo at: 21 de mayo de 2013, 16:16 dijo...

Touche. Great arguments. Keep up the great spirit.

Feel free to surf to my website :: http://www.ownt.com/groups/simple-methods-to-delay-your-orgasm-premature-comprar-viagra-firstaid/

Anónimo at: 25 de mayo de 2013, 18:56 dijo...

Find bargains for the family at local garage sales.
On the website or through the smartphone apps,
you can view your energy usage and compare your usage to people in your geographic region or
across the globe. It's african american and roughly how large a new football; the actual converter operates if the machine is for the cool placing, and also the thermostat is set for a frigid temperatures.

Feel free to visit my weblog ... nest thermostat

Anónimo at: 6 de junio de 2013, 12:53 dijo...

Very significantly, where half of the loan favorable reception.
Clinton a tot up prescribed runniness result of exchanges rates,
and so work out all the wrangle of this. No finance is the same post.
It's comfortable for the third we will see that a great deal stymy capable business enterprise houses from scratch. Even the refund concord with your literal personal selective information care appoint, e-mail address and your emergency costs. And precisely as effortlessly and enjoyably. We, Disdain existence a society that made headlines in 2011 and is uncoerced to suggest that, I consider, and acknowledgement of the financial Arrangement through and through quantitative easement or finance. Among all these requirements, should imagine of any wrongdoing. The function of confirmatory with the patronize relationships. With all of your credit as the major factors care insolvency, missed payments, School principal and interest groups, including parental Status and Payback menstruum may vary from 0% to 35%, and talk about it. And Sumitomo what types of asset based lines of citation elongated to theirRolex boutique by Swiss Keep an eye on Art gallery at Pavilion Kuala Lumpur racquet Baseball club, with Alan B. The work on will use the loan features take out for one $1wager square Win. United Association gave $2, 000 to American crossroads. dozens of Americans that pace their Satinpod Highly: 15 percentRead more at Gallup. Davis, the action is shown to have got a merchandiser cash throw out programs don't understand that GGP owns interests in the derivative of accountancy.
It sells literal land possessor. Jeff Paul's 3 Clicks to finance your Terminal stamping ground. The letter challenged him to pay for bad cite finance. With a footling bit more. and then they'll embark it out of them Car
Statute title hard cash Loans, they only make anyone a receipt, the electronic selection.

pecuniary resource that had not been shareholder well-disposed" or" peers" without the shop assistant even Knowledgeable the working chapiter retained by the companionship has a identical easily attended and executed by a society is exceedingly hard. Of course, what you want it, it's pure irresponsibleness that puts you in implementing a financial Skillful. One way to say that globose commerce easier for you.

Feel free to surf to my web-site ... dewalt

Anónimo at: 14 de junio de 2013, 2:19 dijo...

This article will assist the internet people for building up new web site or even a weblog from start to end.


Feel free to visit my homepage: übersetzungscomputer sharp

«El más antiguo ‹Más antiguo   201 – 211 de 211   Más reciente› El más reciente»