Skip to content

Commit

Permalink
Minor fix
Browse files Browse the repository at this point in the history
  • Loading branch information
cp-radhika-s committed Aug 14, 2023
1 parent b744996 commit 2f1be43
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 9 deletions.
2 changes: 1 addition & 1 deletion countrypicker/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ plugins {

ext {
PUBLISH_GROUP_ID = 'com.canopas.jetcountrypicker'
PUBLISH_VERSION = '1.0.8'
PUBLISH_VERSION = '1.0.8-alpha01'
PUBLISH_ARTIFACT_ID = 'jetcountrypicker'
}
apply from: "${rootDir}/scripts/publish-module.gradle"
Expand Down
23 changes: 15 additions & 8 deletions scripts/publish-module.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,15 @@ apply plugin: 'signing'

task androidSourcesJar(type: Jar) {
archiveClassifier.set('sources')
from android.sourceSets.main.java.srcDirs
if (project.plugins.findPlugin("com.android.library")) {
from android.sourceSets.main.java.srcDirs
} else {
from sourceSets.main.java.srcDirs
}
}

artifacts {
archives androidSourcesJar
}

group = PUBLISH_GROUP_ID
Expand All @@ -20,14 +28,13 @@ afterEvaluate {
artifactId PUBLISH_ARTIFACT_ID
version PUBLISH_VERSION
artifact androidSourcesJar
/// Two artifacts, the `aar` (or `jar`) and the sources
// if (project.plugins.findPlugin("com.android.library")) {
from components.release
// } else {
// artifact("$buildDir/libs/${project.getName()}-${version}.jar")
// }
// Two artifacts, the `aar` (or `jar`) and the sources
if (project.plugins.findPlugin("com.android.library")) {
} else {
artifact("$buildDir/libs/${project.getName()}-${version}.jar")
}

// artifact androidSourcesJar
artifact androidSourcesJar

// Mostly self-explanatory metadata
pom {
Expand Down

0 comments on commit 2f1be43

Please sign in to comment.