maven-3

Maven deploy artifact

青春壹個敷衍的年華 提交于 2021-02-11 15:18:06
问题 I am using mvn deploy:deploy-file to upload a artifact to the remote repository. I am having - Apache2.2 and Maven-3.0.3 Following is the command I am using - mvn -X deploy:deploy-file -Durl=http://myRepos.com/repo/ -DrepositoryId=repo-mine -Dfile=temp.jar -DgroupId=com.yagnaiq -DartifactId=temp -Dversion=1.0 -Dpackaging=jar -Dclassifier=test -DgeneratePom=true -DgeneratePom.description="My POM" -DrepositoryLayout=default -DuniqueVersion=false My settings.xml contains an entry for

maven jar deployed twice in a war module with attachClasses set to true

萝らか妹 提交于 2021-02-11 12:15:15
问题 I am trying to use module as a dependency in another project by deploying it to our nexus repository. The problem is that maven tries to deploy the jar twice and our policy forbids to overwrite a release version. The module is packaged as a war. Here is my configuration. <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-war-plugin</artifactId> <version>2.3</version> <executions> <execution> <id>build-war</id> <phase>package</phase> <goals> <goal>war</goal> </goals> <

Maven Repositories for Spring Roo

≯℡__Kan透↙ 提交于 2021-02-09 11:59:06
问题 My intent is to proxy Roo Maven repository with my local Nexus installation, so that it will contain Roo 1.2.0.RELEASE packages. On http://static.springsource.org/spring-roo/reference/html/resources.html it is written that Roo builds are published on http://spring-roo-repository.springsource.org/release. Unfortunately that link returns error NoSuchKey . Is there some other Maven repository to get Roo packages from ? 回答1: Create (in Nexus) a proxy repository with the remote storage location =

What is the best way to externalize properties in pom.xml

醉酒当歌 提交于 2021-02-08 17:20:42
问题 I have a few mvn projects with almost the same properties. What is the best way to externalize these properties so i dont have them duplicated. First the properties: <properties> <!-- LOMBOK version --> <lombok.version>1.16.4</lombok.version> <!-- LOGGING versions --> <slf4j.version>1.6.4</slf4j.version> <log4j.version>1.2.16</log4j.version> <!-- MAVEN COMPILER PLUGIN version --> <maven-compiler-plugin.version>3.3</maven-compiler-plugin.version> <maven-compiler-plugin.source.version>1.7<

SLFJ4 bridge for the Maven logger

余生长醉 提交于 2021-02-08 05:36:38
问题 I'm writing a Maven 3.x plugin and want to log with SLF4J & Logback. I found some SLF4J bindings for the Maven Logger: http://www.jcabi.com/jcabi-maven-slf4j/index.html https://bitbucket.org/peachjean/slf4j-mojo However, these seem to be SLF4J bindings but I believe what I need is a bridge for the Maven Logger i.e. to bridge/route all Maven log statements to SLF4J and use LogBack binding with logback.xml config. 回答1: You can use SLF4J directly from Maven plugin since Maven 3.1: The standard

build multiple projects using maven in eclipse

拟墨画扇 提交于 2021-02-08 04:43:15
问题 I have 7 projects in my local environment and some of them depend on each other. I have built them in a particular sequence to prepare my development environment. I have to do update dependency and then maven clean install on each project in a particular sequence for this. Is there any shortcut to do this instead of the manual steps? How do I create a run configuration ( or any other way) to build all projects in some sequence? -Sunil 回答1: If these 7 projects are parts of a whole project then

build multiple projects using maven in eclipse

折月煮酒 提交于 2021-02-08 04:42:09
问题 I have 7 projects in my local environment and some of them depend on each other. I have built them in a particular sequence to prepare my development environment. I have to do update dependency and then maven clean install on each project in a particular sequence for this. Is there any shortcut to do this instead of the manual steps? How do I create a run configuration ( or any other way) to build all projects in some sequence? -Sunil 回答1: If these 7 projects are parts of a whole project then

Using cached artifacts in Maven to avoid redundant builds?

自闭症网瘾萝莉.ら 提交于 2021-02-07 19:18:22
问题 I have a Maven 3 multi-module project (~50 modules) which is stored in Git. Multiple developers are working on this code and building it, and we also have automated build machines that run cold builds on every push. Most individual changelogs alter code in a fairly small number of modules, so it's a waste of time to rebuild the entire source tree with every change. However, I still want the final result of running the parent project build to be the same as if it had built the entire codebase.

How to set both VM Params and Program args using exec-maven-plugin?

你。 提交于 2021-02-07 18:13:33
问题 I am using exec-maven-plugin to run java app. I need to pass both JVM params and program arguments. I am setting JVM params like this: <artifactId>exec-maven-plugin</artifactId> <version>1.6.0</version> <executions> <execution> <id>MyId</id> <goals> <goal>java</goal> </goals> <configuration> <mainClass>MyClass</mainClass> <arguments> <argument>-XX:+UseG1GC</argument> <argument>-Xms2G</argument> <argument>-Xmx2G</argument> </arguments> </configuration> </execution> ... and run the program: mvn

How to set both VM Params and Program args using exec-maven-plugin?

落花浮王杯 提交于 2021-02-07 18:08:56
问题 I am using exec-maven-plugin to run java app. I need to pass both JVM params and program arguments. I am setting JVM params like this: <artifactId>exec-maven-plugin</artifactId> <version>1.6.0</version> <executions> <execution> <id>MyId</id> <goals> <goal>java</goal> </goals> <configuration> <mainClass>MyClass</mainClass> <arguments> <argument>-XX:+UseG1GC</argument> <argument>-Xms2G</argument> <argument>-Xmx2G</argument> </arguments> </configuration> </execution> ... and run the program: mvn