From aee749d87f0a2badd19535a63a0c1f14660f099e Mon Sep 17 00:00:00 2001 From: Adubbz Date: Tue, 15 Dec 2015 20:42:05 +1100 Subject: [PATCH] Reverting build file --- build.gradle | 128 ++++++++++++++++++++++++--------------------------- 1 file changed, 61 insertions(+), 67 deletions(-) diff --git a/build.gradle b/build.gradle index f5eb7de7f..3d2d00440 100644 --- a/build.gradle +++ b/build.gradle @@ -107,78 +107,72 @@ artifacts { uploadArchives { dependsOn 'build' - repositories { - if (project.hasProperty("filesmaven")) { + + repositories.mavenDeployer { + if ("$System.env.maven_username" != "null" && "$System.env.maven_password" != "null") { logger.info('Publishing to files server') - - mavenDeployer { - configuration = configurations.deployJars - repository(url: project.filesmaven.url) { - authentication(userName: project.filesmaven.username, privateKey: project.filesmaven.key) - } - - // This is just the pom data for the maven repo - pom { - groupId = project.group - version = project.version - artifactId = project.archivesBaseName - project { - name project.archivesBaseName - packaging 'jar' - description 'Biomes O Plenty' - url 'https://github.com/Glitchfiend/BiomesOPlenty' - - scm { - url 'https://github.com/Glitchfiend/BiomesOPlenty' - connection 'scm:git:git://github.com/Glitchfiend/BiomesOPlenty.git' - developerConnection 'scm:git:git@github.com:Glitchfiend/BiomesOPlenty.git' - } - - issueManagement { - system 'github' - url 'https://github.com/Glitchfiend/BiomesOPlenty/issues' - } - - licenses { - license { - name 'Creative Commons Attribution-NonCommercial-NoDerivs 4.0 International Public License' - url 'http://creativecommons.org/licenses/by-nc-nd/4.0/' - distribution 'repo' - } - } - - developers { - developer { - id 'Adubbz' - name 'Adubbz' - roles { role 'developer' } - } - developer { - id 'Amnet' - name 'Amnet' - roles { role 'developer' } - } - developer { - id 'Forstride' - name 'Forstride' - roles { role 'developer' } - } - developer { - id 'ted80' - name 'ted80' - roles { role 'developer' } - } - } - } - } + repository(url: "http://files.minecraftforge.net/maven/manage/upload") { + authentication(userName: "$System.env.maven_username", privateKey: "$System.env.maven_password") } } else { logger.info('Publishing to repo folder') - - mavenDeployer { - pom.version = "${project.minecraft.version}-${project.version}" - repository(url: 'file://localhost/' + project.file('repo').getAbsolutePath()) + + pom.version = "${project.minecraft.version}-${project.version}" + repository(url: 'file://localhost/' + project.file('repo').getAbsolutePath()) + } + + pom { + groupId = project.group + version = project.version + artifactId = project.archivesBaseName + project { + name project.archivesBaseName + packaging 'jar' + description 'Biomes O Plenty' + url 'https://github.com/Glitchfiend/BiomesOPlenty' + + scm { + url 'https://github.com/Glitchfiend/BiomesOPlenty' + connection 'scm:git:git://github.com/Glitchfiend/BiomesOPlenty.git' + developerConnection 'scm:git:git@github.com:Glitchfiend/BiomesOPlenty.git' + } + + issueManagement { + system 'github' + url 'https://github.com/Glitchfiend/BiomesOPlenty/issues' + } + + licenses { + license { + name 'Creative Commons Attribution-NonCommercial-NoDerivs 4.0 International Public License' + url 'http://creativecommons.org/licenses/by-nc-nd/4.0/' + distribution 'repo' + } + } + + developers { + developer { + id 'Adubbz' + name 'Adubbz' + roles { role 'developer' } + } + developer { + id 'Amnet' + name 'Amnet' + roles { role 'developer' } + } + developer { + id 'Forstride' + name 'Forstride' + roles { role 'developer' } + } + developer { + id 'ted80' + name 'ted80' + roles { role 'developer' } + } + } } } }