Show pageBacklinksBack to top This page is read only. You can view the source, but not change it. Ask your administrator if you think this is wrong. ====== Add Local Repository for Project ====== Assume we want yo create a local maven repository for a project. We locate it in ./libs under the project directory. After running this script, you will see a new directory /libs created. <code> mvn install:install-file -Dfile=your-jar-file-name-1.0.0.jar -DgroupId=com.exmaple -DartifactId=your-jar-file-name - Dversion=1.0.0 -Dpackaging=jar -DlocalRepositoryPath=./libs </code> In pom.xml, add repositories: <code> <project .... . . . <repositories> <repository> <id>in-project</id> <name>In Project Repo</name> <url>file://${project.basedir}/libs</url> </repository> </repositories> </code> and now you can add the dependency: <code> <dependency> <groupId>com.example</groupId> <artifactId>your-jar-file-name</artifactId> <version>1.0.0</version> </dependency> </code> maven/add_local_repository_for_project.txt Last modified: 2021/01/06 19:39by chongtin