[wp_ad_camp_1]
Sometimes you may not have access to a repository and may need to go around it. If your colleagues have local copies of jar files needed to compile a whole Maven project, you may simply replace the content of your .m2 directory with theirs. But what if there was change to your pom.xml and none of you had fetched the updates/dependencies via Maven? Worse, you may not have direct access to their respective repositories.
If those dependencies (e.g., jar files)are found elsewhere, you may download them and modify your pom.xml to point to those local copies. Not really a good practice but something nice-to-know in case you need a short-cut.
Maven Dependency using systemPath
1 2 3 4 5 6 7 | <dependency> <groupId>uk.me.jstott</groupId> <artifactId>jcoord</artifactId> <version>1.0</version> <scope>system</scope> <systemPath>${project.basedir}/localjar/jcoord-1.0.jar</systemPath> </dependency> |
This is how your project structure would look like:
[wp_ad_camp_5]