I want to download not-jar file from repository. I want to do it via task. I have this code but it does nothing when I call the function.
repositories {
maven {
url: abc.com
}
}
configurations { archives { transitive = false } }
dependencies { archives "group:programm:version1" } // this file exists in abc.com with .zip extension
task getArchives(type: Sync){
from configurations.archives
into "dest_dir"
}
abc.com is artifactory, but don't think that it is relevant
CodePudding user response:
Below is a working example, you can change the task to your extract.
configurations {
zipDist
}
dependencies {
zipDist 'org.apache.openejb:javaee-api:6.0-6@zip'
}
task testZip(type: Zip) {
from configurations.zipDist
}
artifacts {
zipDist testZip
}