I have a requirement where i have to check if artifact version is already present or nexus or not. if already present then fail the build else proceed with the deployment.
I tried this curl command to fetch.. but i'm getting error
curl -s -k --user ${credentials} \"${nexusHost}/service/local/artifact/maven/content?r=${repository}&g=${groupId}&a=${artifactId}&v=${version}&p=${packaging}\" -o ${fileName} &> /dev/null
where repository i'm giving "snapshots" .
But this is throwing error. Please help me out here
HTTP ERROR: 404
Problem accessing /service/rest/beta/search/assets. Reason:
Powered by Jetty:// – garima May 12 '20 at 12:27