-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
36 lines (29 loc) · 876 Bytes
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
plugins {
id 'maven-publish'
id 'de.undercouch.download' version '3.1.0'
id 'distribution'
}
version = '1.0'
ext.gradleVersion = '2.13'
task downloadGradle(type: de.undercouch.gradle.tasks.download.Download) {
onlyIfNewer true
src "http://services.gradle.org/distributions/gradle-${gradleVersion}-bin.zip"
dest "${buildDir}/download/gradle.zip"
}
task gradleDistribution(type: Zip, dependsOn: downloadGradle) {
from zipTree(downloadGradle.dest)
into "gradle-${gradleVersion}/init.d", {
from 'src/init.d'
}
archiveName "sample-gradle-bin.zip"
destinationDir file("${buildDir}/distribution")
}
publishing {
publications {
gradle(MavenPublication) {
groupId 'sample'
artifactId 'sample-gradle-distribution'
artifact gradleDistribution
}
}
}