English 中文(简体)
你们怎么能够把一把ant子的造案记录重新添加到一jar中的所有档案?
原标题:How can you tell an ant build file to recursively add all files in the bin directory to a jarfile?
  • 时间:2011-08-29 17:28:33
  •  标签:
  • ant
  • jar

我有以下ant建档案,本应将本目录中的所有类别档案整理成册:

<?xml version="1.0" encoding="utf-8"?>
<project name="RemoteJunitXletServer.makejar" default="makejar" basedir=".">
    <target name="makejar" description="Build a jarfile based on the JunitServer project">
        <jar jarfile="JunitServer.jar" includes="**.class" basedir="bin" />
    </target>
</project>

不幸的是,包括“**.等”在内的只有两个深层的目录,而且没有复制任何在双倍复印机内超过两个目录的档案。 是否明确宣布这些名录? 还是能够告诉安特,在保存文件夹结构的同时,仅复制本夹中的所有类别档案?

最佳回答

Try includes=**/**.密特>.

问题回答

暂无回答




相关问题
Refactor packages in a Jar

I have a requirement that i need to load two versions of a jar at once. To avoid class path collisions I d like to rename the packages of one of the jars. Then in source you could always easily ...

Directory list of JAR file within classpath

The typically method to reference a file contained with a JAR file is to use ClassLoader.getResource. Is there a way to get the contents of a directory within a JAR files (similar to java.io.File....

Including dependencies in a jar with Maven

Is there a way to force maven(2.0.9) to include all the dependencies in a single jar file? I have a project the builds into a single jar file. I want the classes from dependencies to be copied into ...

Jar file resource not available?

My program has the following lines, works fine when run from Netbeans, JButton Button_1=new JButton(new ImageIcon(Phone_Dialer.class.getResource("Dir_Icons/"+"Key_1"+Botton_Color+".gif"))); But ...

Include jar file in Scala interpreter

Is it possible to include a jar file run running the Scala interpreter? My code is working when I compile from scalac: scalac script.scala -classpath *.jar But I would like to be able to include a ...

loading from JAR files during deployment vs development

when i am loading some data into my java program, i usually use FileInputStream. however i deploy the program as a jar file and webstart, so i have to use getRessource() or getRessourceAsStream() to ...

热门标签