maven local repository에 jar 추가

개발툴|2013. 3. 20. 20:59

FTP 모듈을 사용하게 될 일이 생겨 예전에 만들었던 FTP 프로그램을 메이븐 프로젝트로 옮기게 되었다. 


내가 만든 FTP 모듈은 NetComponents-1.3.8.jar 라이브러리를 필요로 하는데 메이븐 중앙 리포지토리에서는 해당 라이브러리를 관리 안하고 있었다.


결국 아래와 같은 명령어를 이용하여 .m2\repository 디렉토리에 NetComponents-1.3.8.jar를 추가하여 문제를 해결 할 수 있었다.


mvn install:install-file -Dfile=C:\NetComponents-1.3.8.jar -DgroupId=com.oroinc -DartifactId=NetComponents -Dversion=1.3.8 -Dpackaging=jar -DgeneratePom=true


빨간색 글씨 부분을 상황에 맞게 변경해 주면 되고, 명령어를 실행하면 .m2\repository 경로에 class 파일이 install 된다.



NetComponents-1.3.8.jar


댓글()