@@ -31,93 +31,24 @@ dependencies {
3131}
3232
3333ext {
34- bintrayRepo = ' maven'
35- bintrayName = ' android-test-xrunner'
36-
37- publishedGroupId = ' com.stepstone.xrunner'
34+ artifactGroupId = ' com.stepstone.xrunner'
3835 libraryName = ' Android Test XRunner'
39- artifact = ' xrunner-library'
36+ artifactId = ' xrunner-library'
4037
4138 libraryDescription = ' Running UI tests multiple times made easy'
4239
4340 siteUrl = ' https://github.com/stepstone-tech/AndroidTestXRunner'
44- gitUrl = ' https://github.com/stepstone-tech/AndroidTestXRunner.git'
4541
46- libraryVersion = ' 2.1 .0'
42+ libraryVersion = ' 2.2 .0'
4743
4844 licenseName = ' The Apache Software License, Version 2.0'
4945 licenseUrl = ' http://www.apache.org/licenses/LICENSE-2.0.txt'
50- allLicenses = [" Apache-2.0" ]
5146}
5247
5348task sourcesJar (type : Jar ) {
54- classifier = ' sources'
49+ getArchiveClassifier() . set( " sources" )
5550 from android. sourceSets. main. java. srcDirs
5651}
5752
58- dokkaJavadoc. configure {
59- dokkaSourceSets {
60- named(" main" ) {
61- noAndroidSdkLink. set(false )
62- }
63- }
64- }
65-
66- task javadocJar (type : Jar , dependsOn : dokkaJavadoc) {
67- classifier = ' javadoc'
68- from " $buildDir /dokka/javadoc"
69- }
70-
71- publishing {
72- publications {
73- MyPublication (MavenPublication ) {
74-
75- artifact sourcesJar
76- artifact javadocJar
77- artifact(" $buildDir /outputs/aar/xrunner-library-release.aar" )
78-
79- groupId publishedGroupId
80- artifactId artifact
81- version libraryVersion
82-
83- pom {
84- packaging ' aar'
85- withXml {
86-
87- asNode(). appendNode(' name' , libraryName)
88-
89- asNode(). appendNode(' description' , libraryDescription)
90-
91- asNode(). appendNode(' url' , siteUrl)
92-
93- // License
94- def licensesNode = asNode(). appendNode(' licenses' )
95- def licenseNode = licensesNode. appendNode(' license' )
96- licenseNode. appendNode(' name' , licenseName)
97- licenseNode. appendNode(' url' , licenseUrl)
98-
99- // Git
100- def scmNode = asNode(). appendNode(' scm' )
101- scmNode. appendNode(' connection' , gitUrl)
102- scmNode. appendNode(' developerConnection' , gitUrl)
103- scmNode. appendNode(' url' , siteUrl)
104-
105- def dependenciesNode = asNode(). appendNode(' dependencies' )
106-
107- // Iterate over the implementation dependencies (we don't want the test ones), adding a <dependency> node for each
108- configurations. implementation. allDependencies. each {
109- // Ensure dependencies such as fileTree are not included.
110- if (it. name != ' unspecified' ) {
111- def dependencyNode = dependenciesNode. appendNode(' dependency' )
112- dependencyNode. appendNode(' groupId' , it. group)
113- dependencyNode. appendNode(' artifactId' , it. name)
114- dependencyNode. appendNode(' version' , it. version)
115- }
116- }
117- }
118- }
119- }
120- }
121- }
122-
12353publishToMavenLocal. dependsOn ' assembleRelease'
54+ apply from : " scripts/publish-module.gradle"
0 commit comments