-
Notifications
You must be signed in to change notification settings - Fork 40
/
jcenter.gradle
executable file
·88 lines (80 loc) · 2.41 KB
/
jcenter.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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
apply plugin: 'com.jfrog.bintray'
apply plugin: 'com.github.dcendents.android-maven'
Properties properties = new Properties()
properties.load(project.rootProject.file('local.properties').newDataInputStream())
def siteUrl = 'https://github.com/imuhao/RxPicker'
def gitUrl = 'https://github.com/imuhao/RxPicker.git'
versionName = "1.1.5"
group = "com.caimuhao"
bintray {
user = properties.getProperty("bintray.user")
key = properties.getProperty("bintray.apikey")
pkg {
repo = 'maven' //自己bintray创建仓库名字
name = 'RxPicker' //Library的名字
websiteUrl = siteUrl
vcsUrl = gitUrl
licenses = ['MIT'] //不能随便写,只能是仓库创建时选择的license type
userOrg = 'muhaocai' //自己bintray创建的organization名称
publish = true // 是否是公开项目。
version {
name = versionName
desc = 'The ImageSelect tool based on RxJava.'
released = new Date()
vcsTag = 'v' + versionName
attributes = ['gradle-plugin': 'com.use.less:com.use.less.gradle:gradle-useless-plugin']
}
}
configurations = ['archives']
}
install {
repositories.mavenInstaller {
// This generates POM.xml with proper parameters
pom {
project {
packaging 'aar'
// Add your description here
name 'RxPicker'
description 'The ImageSelect tool based on RxJava.'
url siteUrl
// Set your license
licenses {
license {
name 'MIT'
url 'https://raw.githubusercontent.com/minggo620/Pluto-Android/master/LICENSE'
}
}
developers {
developer {
id 'imuhao' //填写bintray或者github的用户名
name 'caimuhao' //姓名,可以是中文
email 'caimuhao@gmail.com'
}
}
scm {
connection gitUrl
developerConnection gitUrl
url siteUrl
}
}
}
}
}
task sourcesJar(type: Jar) {
from android.sourceSets.main.java.srcDirs
classifier = 'sources'
}
task javadoc(type: Javadoc) {
failOnError false //必须添加以免出错
source = android.sourceSets.main.java.srcDirs
classpath += project.files(android.getBootClasspath().join(File.pathSeparator))
}
task javadocJar(type: Jar, dependsOn: javadoc) {
classifier = 'javadoc'
from javadoc.destinationDir
}
artifacts {
archives javadocJar
archives sourcesJar
}
//./gradlew --stop; ./gradlew clean bU