Skip to content

Commit

Permalink
Merge pull request #8 from anuchandy/gradlefix
Browse files Browse the repository at this point in the history
Removed gitrevisions
  • Loading branch information
jianghaolu committed Apr 28, 2016
2 parents 2a37759 + d56d5e0 commit 82bdc8b
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 71 deletions.
13 changes: 1 addition & 12 deletions azure-android-client-authentication/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -95,16 +95,6 @@ uploadArchives {
}
}

task versionInfo(type:Exec){
commandLine 'git rev-parse HEAD'.split()
ext.versionfile = new File("${projectDir}/.gitrevision")
standardOutput = new ByteArrayOutputStream()

doLast {
versionfile.text = "Azure/autorest#" + standardOutput.toString()
}
}

task sourcesJar(type: Jar) {
from android.sourceSets.main.java.srcDirs
classifier = 'sources'
Expand All @@ -116,13 +106,12 @@ task javadoc(type: Javadoc) {
options.encoding = 'UTF-8'
}

task javadocJar(type: Jar, dependsOn: [javadoc, versionInfo]) {
task javadocJar(type: Jar, dependsOn: [javadoc]) {
classifier = 'javadoc'
from javadoc.destinationDir
}

artifacts {
archives sourcesJar
archives javadocJar
archives file: file("${projectDir}/.gitrevision")
}
13 changes: 1 addition & 12 deletions azure-client-authentication/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -70,16 +70,6 @@ test {
}
}

task versionInfo(type:Exec){
commandLine 'git rev-parse HEAD'.split()
ext.versionfile = new File("${projectDir}/.gitrevision")
standardOutput = new ByteArrayOutputStream()

doLast {
versionfile.text = "Azure/autorest#" + standardOutput.toString()
}
}

javadoc {
options.encoding = 'UTF-8'
}
Expand All @@ -89,15 +79,14 @@ task sourcesJar(type: Jar, dependsOn:classes) {
from sourceSets.main.allSource
}

task javadocJar(type: Jar, dependsOn: [javadoc, versionInfo]) {
task javadocJar(type: Jar, dependsOn: [javadoc]) {
classifier = 'javadoc'
from javadoc.destinationDir
}

artifacts {
archives sourcesJar
archives javadocJar
archives file: file("${projectDir}/.gitrevision")
}

test {
Expand Down
13 changes: 1 addition & 12 deletions azure-client-runtime/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -69,16 +69,6 @@ test {
}
}

task versionInfo(type:Exec){
commandLine 'git rev-parse HEAD'.split()
ext.versionfile = new File("${projectDir}/.gitrevision")
standardOutput = new ByteArrayOutputStream()

doLast {
versionfile.text = "Azure/autorest#" + standardOutput.toString()
}
}

javadoc {
options.encoding = 'UTF-8'
}
Expand All @@ -88,15 +78,14 @@ task sourcesJar(type: Jar, dependsOn:classes) {
from sourceSets.main.allSource
}

task javadocJar(type: Jar, dependsOn: [javadoc, versionInfo]) {
task javadocJar(type: Jar, dependsOn: [javadoc]) {
classifier = 'javadoc'
from javadoc.destinationDir
}

artifacts {
archives sourcesJar
archives javadocJar
archives file: file("${projectDir}/.gitrevision")
}

test {
Expand Down
13 changes: 1 addition & 12 deletions client-runtime/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -80,16 +80,6 @@ test {
}
}

task versionInfo(type:Exec){
commandLine 'git rev-parse HEAD'.split()
ext.versionfile = new File("${projectDir}/.gitrevision")
standardOutput = new ByteArrayOutputStream()

doLast {
versionfile.text = "Azure/autorest#" + standardOutput.toString()
}
}

javadoc {
options.encoding = 'UTF-8'
}
Expand All @@ -99,15 +89,14 @@ task sourcesJar(type: Jar, dependsOn:classes) {
from sourceSets.main.allSource
}

task javadocJar(type: Jar, dependsOn: [javadoc, versionInfo]) {
task javadocJar(type: Jar, dependsOn: [javadoc]) {
classifier = 'javadoc'
from javadoc.destinationDir
}

artifacts {
archives sourcesJar
archives javadocJar
archives file: file("${projectDir}/.gitrevision")
}

test {
Expand Down
23 changes: 0 additions & 23 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -244,29 +244,6 @@
<artifactId>maven-release-plugin</artifactId>
<version>2.5.2</version>
</plugin>

<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>1.10</version>
<executions>
<execution>
<id>attach-artifacts</id>
<phase>package</phase>
<goals>
<goal>attach-artifact</goal>
</goals>
<configuration>
<artifacts>
<artifact>
<file>target/.gitrevision</file>
<type>gitrevision</type>
</artifact>
</artifacts>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</pluginManagement>
</build>
Expand Down

0 comments on commit 82bdc8b

Please sign in to comment.