maven-antrun-plugin

maven-antrun-plugin skip target if any of two possible conditions holds

孤者浪人 提交于 2019-12-19 09:38:50
问题 I can pass two properties A and B to maven via mvn test -DA=true or mvn test -DB=true If either A or B is defined i want a target to be skipped. I found it was possible when only A was considered like this: <plugin> <artifactId>maven-antrun-plugin</artifactId> <version>1.7</version> <executions> <execution> <id>skiptThisConditionally</id> <phase>test</phase> <configuration> <target name="anytarget" unless="${A}"> <echo message="This should be skipped if A or B holds" /> </target> <

Copying files from source directory to destination directory using ant

淺唱寂寞╮ 提交于 2019-12-13 21:56:12
问题 I want to copy some specific files from source directory to destination directory on below condition using ANT. Source folder contains the following files 35001_abc.sql 38001_abc.sql 38002_abc.sql 39001_abc.sql I want to copy the files with filenames starting with 36000 and above. The Output directory should contain the following files 38001_abc.sql 38002_abc.sql 39001_abc.sql 回答1: One idea is to use a regular expression on the filename to restrict ranges of digits. Example ├── build.xml ├──

antrun input task doesn't work during mvn release:prepare operation

孤街醉人 提交于 2019-12-13 03:02:43
问题 I try to use property with maven-antrun-plugin. But it seems to be blocked in some case (I had the similar problem with exec-maven-plugin : It work with sudo mvn package : The script 0_init_livraison.ksh is executed. After this, execution, antrun asked me a question "Souhaitez-vous continuer ?" If the answer is yes, the build can continue. If the answer is no the script send an error message and the build is stopped. It don't work with sudo mvn release:prepare : antrun ask the question and

Maven ant task not getting executed while running cucumber tests

旧城冷巷雨未停 提交于 2019-12-13 02:54:13
问题 We are trying to set up cucumber framework tests. We started with sample tests and it ran fine. I then updated maven to have maven profiles which will do certain tasks specific to that profile. I have profile QA_Smoke and have ant task under it ( for now simple echo) . I have set this profile as active maven profile but whenever I run the profile , task does not get executed. Instead it directly starts cucumber tests. Below is snapshot of maven profile.Can someone please tell,how can we

Why is my target not getting executed?

风格不统一 提交于 2019-12-13 01:44:49
问题 I am trying to get ready for deployment and therefore I want to copy the correct configuration files to WEB-INF/classes/ before everything gets packed into the WAR file for either deployment or development . In the end I want to execute deployment-tasks whenever I call mvn glcoud:deploy - which is when I need deployment configuration files - and development-tasks whenever something else gets executed in my project directory. At the moment I have not decided how exactly I'm going to do it but

Using maven ant plugin in javafx application, How to add Dependencies in javaFX jar. Still facing class not found exception

牧云@^-^@ 提交于 2019-12-11 20:58:45
问题 I using this guide added my dependencies to main jar JavaFX jar with dependencies bundled i am facing dependencies issue which causing Class not found exception. My Pom is exactly like mentioned in above link. i use dependencies plugin to copy dependencies to lib folder in target. Here is my stack trace Try calling Class.forName(com.client.main.App) using classLoader = j ava.net.URLClassLoader@3c9076d found class: class com.client.main.App launchApp: Try calling com.sun.javafx.application

Error while installing features using POM in wso2

≡放荡痞女 提交于 2019-12-11 15:06:17
问题 i have tried to install features using the below method (https://docs.wso2.org/display/Carbon420/Installing+Features+using+pom+Files) I want to install the features using this method (instead of through UI) While building through maven,the features and plugins are properly inserted into the corresponding folder structure, but it's not updating the platform.xml and bundles.info file Can anyone help me on this... There is a bug in this Maven Installation i think Please help me ... Below is my

Running external Ant file from a parent pom

允我心安 提交于 2019-12-11 10:11:10
问题 I would like to run an Ant build.xml build from a parent POM. This may look like this: <project> <groupId>my.group</groupId> <artifactId>my-parent</artifactId> <version>1.0.0-SNAPSHOT</version> <packaging>pom</packaging> <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-antrun-plugin</artifactId> <executions> <execution> <phase>initialize</phase> <configuration> <tasks> <ant antfile="build.xml"/> </tasks> </configuration> <goals> <goal>run</goal> </goals

How to setup multiple fitnesse suites in pom file using maven-antrun-plugin ? and how to call the specific suite run among the configured suits?

耗尽温柔 提交于 2019-12-11 08:44:13
问题 I am able to run the FitNesse suite from maven build with the following setup. <properties> <fitnesse.version>20160618</fitnesse.version> </properties> <dependencies> <dependency> <groupId>org.fitnesse</groupId> <artifactId>fitnesse</artifactId> <version>${fitnesse.version}</version> <scope>runtime</scope> </dependency> <dependency> <groupId>org.fitnesse.plugins</groupId> <artifactId>maven-classpath-plugin</artifactId> <version>1.6</version> <scope>runtime</scope> </dependency> </dependencies

Maven: Can I package only dependencies(without app) in a jar?

非 Y 不嫁゛ 提交于 2019-12-11 06:04:44
问题 I have a legacy JAVA project which uses ant for builds. Since jar dependency management in this project is really tedious, I am planning to integrate maven. I am trying to use maven only for dependency management and keep using ant for builds. I am contemplating to produce a single jar using maven which will contain all the dependencies and then I will include this single jar in classpath of my app. I know this might not be the best approach but is it possible to do this? What might be a