ant

How do you modify an xjc block in ANT build.xml for Java 9?

僤鯓⒐⒋嵵緔 提交于 2019-12-10 12:29:51
问题 I have a build.xml file that uses xjc to generate some Java classes. Everything builds fine in Java 1.8, but updating to Java 9 causes the following error: xjc-gen-boxes: [xjc] C:\Users\dev\Documents\Dev\bc\bcce2\build\gensrc\co\boxes\v2 is not found and thus excluded from the dependency check [xjc] Compiling file:/C:/Users/dev/Documents/Dev/bc/bcce2/co/src/co/kat/install/boxes/Box.xsd BUILD FAILED C:\Users\dev\Documents\Dev\bc\bcce2\co\build.xml:720: java.lang.NoClassDefFoundError: javax/xml

Ant Ivy conf specific retrieve is failing on my published jar

╄→尐↘猪︶ㄣ 提交于 2019-12-10 12:18:16
问题 Building with Ant Ivy, I'm trying to separate my jars into one configuration for 3rd party jars and another configuration for the jars I build and publish. ProjectA uses 3rd party jars and builds a jar that ProjectB depends on, but when I use Ant Ivy confs I can't get ProjectB to retrieve the ProjectA jar. When I execute the ant script for ProjectB, it builds ProjectA fine. The ProjectA build publishes a jar to the local repository. ProjectB retrieves the necessary jars from the public

Groovy AntBuilder, omit conditional attributes, like “setOmitNullAttributes” functionality on MarkupBulder

混江龙づ霸主 提交于 2019-12-10 11:56:18
问题 sample code: def ant = new AntBuilder() ant.'antlib:org.jacoco.ant:agent'( enabled: enabled, property: 'agentvmparam') When that "enabled" parameter is null, I'd like it to be not present in the ant task conversion, not merely "empty". "empty" gets evaluated to "true" http://ant.apache.org/manual/develop.html#set-magic which isn't what I want. xml builder example: def xml = new MarkupBuilder() xml.omitNullAttributes = true xml.root( requiredAttribute:'required', optionalAttribute:

Error building Android app with Cordova 3.1 CLI

99封情书 提交于 2019-12-10 11:18:32
问题 I am attempting to run "cordova build android" through phonegap CLI with Terminal on my Mac. First I downloaded the Android SDK. Then I set up the project and added android. Then I attempted "cordova build android" and received the following error: Error: An error occurred while building the android project. Please install Android target 17 (the Android newest SDK). Make sure you have the latest Android tools installed as well. Run "android" from your command-line to install/update any

ant target to deploy war to tomcat7/webapps

孤人 提交于 2019-12-10 11:05:47
问题 I want to deploy the just created *.war (exploded) to ${TOMCAT_HOME}/webapps using ant target. CONFIGURATION My tomcat version is 7.0.37 and tomcat-users.xml is : <role rolename="tomcat"/> <role rolename="role1"/> <role rolename="manager-gui"/> <user username="tomcat" password="tomcat" roles="tomcat,manager-gui"/> <user username="both" password="tomcat" roles="tomcat,role1,manager-gui"/> <user username="role1" password="tomcat" roles="role1"/> war.properties is : # War Build Properties

Ant and Junit: no xml report being generated

青春壹個敷衍的年華 提交于 2019-12-10 11:04:56
问题 I'm very new to ant and junit. I need junit to create an xml output so I can integrate with team city. The tests run just fine, but I'm not getting any output in the directory that I'm specifying. I'm running on windows 7. I have junit.jar and ant-junit.jar in my ant_home/lib directory. here is my build xml target: <target name="onlyjunit-sikuli" description="Execute All sikuli tests"> <delete dir="${automated}/results/sikuli"/> <mkdir dir="${automated}/results"/> <mkdir dir="${automated}

How to add any number to a property from a property file

五迷三道 提交于 2019-12-10 11:01:37
问题 I have a property base.number=100 in a property file. I want to create values 102, 103, 105, etc, depending on the value to be added. How can I add the numbers to the property and get the added value? 回答1: Ant contrib has a Math task. It can add numbers among other things. Which means you: Read the property Use the math task to add numbers 回答2: You need no additional ant tasks or additional scripting languages for math operations, just use the builtin javascript scripting engine java ships

SVN-ANT copy task doesn't work, svn copy from CLI does, same arguments

。_饼干妹妹 提交于 2019-12-10 10:48:14
问题 I am using SVN ANT version 1.3.1, ANT 1.7.1, Java 1.6u, and the SVN repo is 1.6 (I think - the prod\db\format file says "4".) I have two SVN targets (I wonder if the "commit" task isn't completing before the "copy" task attempts to execute, which is why I will quote it as part of my build.xml.) I am attempting to tag a release as a production version (seems like a fairly common task for an ANT build relying on SVN-ANT, right?) I can do the following on the command line: svn copy http:/

How do you convert a string to uppercase in ant? [duplicate]

别说谁变了你拦得住时间么 提交于 2019-12-10 10:48:02
问题 This question already has answers here : Closed 7 years ago . Possible Duplicate: Ant string functions? I am modifying a wxi file as part of a wix install and updating a guid. As part of the "pedantic" warning setting if a guid is in lowercase the wix build fails. How can I convert the guid to an uppercase string in ant? EDIT: The Ant string functions thread is definitly the way to go - Ant string functions? 回答1: You may use the Ant Plugin Flaka, no need to use a scripting language = <project

How to remove specific Cobertura warning?

China☆狼群 提交于 2019-12-10 10:46:09
问题 When i am running my ANT build script, Cobertura is complaining with the following warning. With that, i am wondering what it means really and how can i turn it off. [ cobertura-instrument] WARN visitEnd, No line number information found for class com.x.y.z.A. Perhaps you need to compile with debug=true? ANT sample below: <target name="instrument" depends="init,compile" > <delete file="cobertura.ser" /> <delete dir="${instrumented}" /> <cobertura-instrument todir="${instrumented}"> <ignore