Create a new folder, put the jar package you want to upload, and build a pom file, such as Xx.jar,pom.xml
First create a directory to facilitate the implementation of the upload URL parameters can also not be created,
Uploading curl - v -u admin:admin123 --upload- XML filepom.xml http://localhost:8081/nexus/repository/maven-releases/com/xx/xx/1.0/xx.pom
Upload jar Package curl - v-u admin:admin123 --upload-file xx.jar http://localhost:8081/nexus/repository/maven-releases/com/xx/xx/1.0/xx.jar
Note that the marked red part needs to be replaced with the location in the warehouse you are uploading.
Using the Curl command under Windows
Download Curl.exe
Address: https://curl.haxx.se/download.html
Place the Curl.exe in the C:\Windows\System32 directory so that you can use the Curl command
After the upload is successful, the Pom.xml in the project can be used
<dependency> <groupId>com.xx</groupId>
</dependency>
Nexus3 Adding a local jar package to the warehouse