-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathupload.gradle
More file actions
39 lines (32 loc) · 1.1 KB
/
upload.gradle
File metadata and controls
39 lines (32 loc) · 1.1 KB
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
//def getVersionNameAdvanced(){
// defxmlFile = project.file("AndroidManifest.xml")
// defrootManifest = new XmlSlurper().parse(xmlFile)
// return rootManifest['@android:versionName']
//}
//
//ext{
// getVersionNameAdvanced = this.&getVersionNameAdvanced
//}
apply plugin: 'maven'
uploadArchives {
repositories {
mavenDeployer {
// flatDir { //发布到本地
// dirs "../maven"
// }
// 三要素,group:artifact:version
pom.project {
groupId project.hasProperty('GROUP_ID') ? GROUP_ID : 'com.garfield'
artifactId project.name
version project.version != 'unspecified' ? project.version : '0.0.1'
description project.description ?: ''
}
snapshotRepository(url: uri(repo_snapshot)) {
authentication(userName: repo_username, password: repo_password)
}
repository(url: uri(repo_release)) {
authentication(userName: repo_username, password: repo_password)
}
}
}
}