Add customized jar as Maven Dependency



Add customized jar as Maven Dependency


  • This example used for creating new customized ReportNG jar as maven dependency.

  1. Go to jar file location.
  2. Open cmd window in the jar located folder.
  3. Run this CMD maven command:

mvn install:install-file -Dfile=reportng-mobileODT.jar -DgroupId=reportng-mobileODT -
DartifactId=reportng-mobileODT -Dversion=1.0 -Dpackaging=jar

  1. After build success, go to pom.xml file in eclipse.
  2. Click on Window => Show View => Other => Maven => Maven Repositiries.
  3. Right click on Local Repositories => Rebuild Index.
  4. Right-click on the project -> Maven -> Add Dependency.
  5. Fill the groupid of jar and fill required fields.
  6. Build project.

Notes:
Please make sure that you have maven installed in your local machine.

Comments

Post a Comment

Popular posts from this blog

How to Customize TestNG Emailable Report ?

Handling Selenium Grid Exceptions