// maven deploy config start configurations { deployerJars } uploadArchives { repositories.mavenDeployer { configuration = configurations.deployerJars repository(url: "http://maven.coder4.com/nexus/content/repositories/releases/") { authentication(userName: "$mavenUser", password: "$mavenPass") } repository(url: "http://maven.coder4.com/nexus/content/repositories/snapshots/") { authentication(userName: "$mavenUser", password: "$mavenPass") } } } // maven deploy config end
以及插件的依赖
dependencies { deployerJars "org.apache.maven.wagon:wagon-http:2.2" .... }