Something like “mvn undeploy” to remove artifacts from Nexus?

Marcus

After a mvn deploy (to a local Nexus) on a project with more than 50 modules I realized that the deployed artifacts had all wrong file names (suffix zip instead of war etc).

Is there something like mvn undeploy to remove these from Nexus again?

Inforedaster

You can delete it by using Curl command :

http://host:port/nexus/service/local/repositories/repo-id/content/group-id/artifact-id/version

The delete request can be sent with these parameters, I like to suppress the output except HTTP status code, so that it’s easier to check the result of a series of such commands run from shell script.

curl –request DELETE –write “%{http_code} %{url_effective}\\n” –user admin:admin123 –output /dev/null –silent url

For example you can execute this script from a Freestyle jenkins job.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related