0

I have a question related to maven - generating a war. Please see below. - In one of my project (war), I am using a 3rd party jar (-SNAPSHOT version) whose entry I have made into my project pom.xml. So far it gets bundled correctly into the project war. - But we encountered one issue in one of the java file inside this jar. For which my developer took the source code for the jar and modified-compiled and updated the jar file into local maven_repo directory. - But whenever I build the project using maven clean:install command, my updated jar gets deleted from my local maven-repo dir and a fresh copy is downloaded from remote maven repo (where the actual 3rd party jar resides).

Can someone please help on this how can I manage so that maven use my modified jar and does not replace it with old jar during build process.

I am using maven-3.2.5.

Jitendra
  • 35
  • 6
  • Hi, Please let me know if anyone need more information on my question. Expecting help as early as possible. – Jitendra Sep 04 '15 at 06:07

1 Answers1

0

you can run maven offline by running with the "-o" argument.

Example:

mvn clean install -o

Keep in mind that this will affect all your other dependencies and your need to have all the dependencies in your local .m2 repository.

Here is another thread taking up the issue of running maven offline: How do I configure Maven for offline development?

Community
  • 1
  • 1
Richard
  • 137
  • 4