Skip to content

Commit 788c98d

Browse files
authored
spb-#5 Prepare library for upload to JitPack (#6)
Co-authored-by: javavirys <javavirys@gmail.com>
1 parent ea53089 commit 788c98d

2 files changed

Lines changed: 22 additions & 1 deletion

File tree

SectorProgressBarLib/build.gradle

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
plugins {
22
id 'com.android.library'
33
id 'kotlin-android'
4+
id 'maven-publish'
45
}
5-
apply plugin: 'kotlin-android'
66

77
android {
88
compileSdk 31
@@ -31,6 +31,22 @@ android {
3131
}
3232
}
3333

34+
task androidSourcesJar(type: Jar) {
35+
classifier 'sources'
36+
from android.sourceSets.main.java.srcDirs
37+
}
38+
39+
project.afterEvaluate {
40+
publishing {
41+
publications {
42+
release(MavenPublication) {
43+
from components.release
44+
artifact androidSourcesJar
45+
}
46+
}
47+
}
48+
}
49+
3450
dependencies {
3551
implementation 'androidx.appcompat:appcompat:1.4.0'
3652
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-android:1.4.3'

jitpack.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
jdk:
2+
- openjdk11
3+
4+
install:
5+
- ./gradlew assemble :SectorProgressBarLib:publishToMavenLocal

0 commit comments

Comments
 (0)