Skip to content

Commit 1b0e589

Browse files
release compatibility artifact in Jitpack
1 parent a0094cd commit 1b0e589

File tree

3 files changed

+56
-0
lines changed

3 files changed

+56
-0
lines changed

code/android-core-compatiblity/build.gradle

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,54 @@ android {
5858
}
5959
}
6060

61+
def isJitPackBuild() {
62+
return hasProperty('jitpack')
63+
}
64+
def groupIdForPublish = isJitPackBuild()? 'com.github.adobe.aepsdk-core-android': 'com.adobe.marketing.mobile'
65+
publishing {
66+
publications {
67+
release(MavenPublication) {
68+
groupId = groupIdForPublish
69+
artifactId = rootProject.compatibilityName
70+
version = rootProject.compatibilityVersion
71+
artifact("$buildDir/outputs/aar/${rootProject.compatibilityAARName}")
72+
73+
pom {
74+
name = rootProject.mavenRepoName
75+
description = rootProject.mavenRepoDescription
76+
url = 'https://aep-sdks.gitbook.io'
77+
licenses {
78+
license {
79+
name = 'Adobe Proprietary'
80+
}
81+
}
82+
developers {
83+
developer {
84+
id = 'adobe'
85+
name = 'adobe'
86+
87+
}
88+
}
89+
scm {
90+
connection = 'scm:git:github.com//Adobe-Marketing-Cloud/acp-sdks.git'
91+
developerConnection = 'scm:git:ssh://github.com//Adobe-Marketing-Cloud/acp-sdks.git'
92+
url = 'https://github.com/Adobe-Marketing-Cloud/acp-sdks'
93+
}
94+
withXml {
95+
def dependenciesNode = asNode().appendNode('dependencies')
96+
97+
def coreDependencyNode = dependenciesNode.appendNode('dependency')
98+
coreDependencyNode.appendNode('groupId', 'com.adobe.marketing.mobile')
99+
coreDependencyNode.appendNode('artifactId', 'core')
100+
coreDependencyNode.appendNode('version', rootProject.coreExtensionVersion)
101+
}
102+
}
103+
}
104+
}
105+
}
106+
tasks.withType(Javadoc).all { enabled = false }
107+
publishToMavenLocal.dependsOn('assemblePhone')
108+
61109
dependencies {
62110
implementation 'androidx.appcompat:appcompat:1.0.0'
63111
implementation project(path: ':android-core-library')

code/gradle.properties

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,3 +36,9 @@ dokka_version = 1.7.0
3636
signalExtensionVersion=2.0.0
3737
signalExtensionName=signal
3838
signalExtensionAARName=android-signal-library-phone-release.aar
39+
40+
#compatibility artifact
41+
compatibilityVersion=2.0.0
42+
compatibilityName=compatibility
43+
compatibilityAARName=android-core-compatiblity-phone-release.aar
44+

jitpack.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,7 @@ install:
77
- ./code/gradlew -p code/android-core-library publishToMavenLocal -Pjitpack
88
- ./code/gradlew -p code/android-signal-library assemblePhone
99
- ./code/gradlew -p code/android-signal-library publishToMavenLocal -Pjitpack
10+
- ./code/gradlew -p code/android-core-compatiblity assemblePhone
11+
- ./code/gradlew -p code/android-core-compatiblity publishToMavenLocal -Pjitpack
1012
# env:
1113
# MYVAR: "custom environment variable"

0 commit comments

Comments
 (0)