forked from signalapp/libsignal-protocol-java
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathbuild.gradle
More file actions
115 lines (103 loc) · 3.19 KB
/
Copy pathbuild.gradle
File metadata and controls
115 lines (103 loc) · 3.19 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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
buildscript {
repositories {
mavenCentral()
google()
jcenter {
content {
includeVersion 'org.jetbrains.trove4j', 'trove4j', '20160824'
}
}
}
dependencies {
classpath 'com.android.tools.build:gradle:8.13.2'
}
}
apply plugin: 'com.android.library'
apply plugin: 'maven-publish'
apply plugin: 'signing'
archivesBaseName = "omemo-android"
version = version_number
group = group_info
description = 'OMEMO library for Android'
android {
namespace 'im.dino.omemo'
compileSdkVersion 28
buildToolsVersion '35.0.0'
defaultConfig {
minSdkVersion 21
targetSdkVersion 28
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
publishing {
singleVariant("release") {
withSourcesJar()
withJavadocJar()
}
}
}
repositories {
mavenCentral()
google()
}
dependencies {
api "im.dino:curve25519-android:${curve25519_version}"
api (project(':java')) {
exclude group: 'im.dino', module: 'curve25519-java'
}
androidTestImplementation (project(":tests"))
androidTestImplementation "androidx.test:runner:1.2.0"
}
afterEvaluate {
publishing {
publications {
release(MavenPublication) {
artifactId = 'omemo-android'
pom {
name = 'omemo-android'
description = project.description
url = 'https://github.com/dino/libomemo-java'
licenses {
license {
name = 'GNU General Public License, Version 3'
url = 'https://www.gnu.org/licenses/gpl-3.0.txt'
}
}
developers {
developer {
id = 'dino'
name = 'Dino Team'
}
}
scm {
url = 'https://github.com/dino/libomemo-java'
connection = 'scm:git:https://github.com/dino/libomemo-java.git'
developerConnection = 'scm:git:ssh://github.com/dino/libomemo-java.git'
}
}
from components.release
}
}
if (project.hasProperty('maven.central.username')) {
repositories {
maven {
name = 'mavenCentral'
url = 'https://ossrh-staging-api.central.sonatype.com/service/local/staging/deploy/maven2/'
credentials {
username project.getProperty('maven.central.username')
password project.getProperty('maven.central.password')
}
}
}
}
}
if (project.hasProperty('signing.gnupg.keyName')) {
signing {
useGpgCmd()
sign publishing.publications
}
}
tasks.getByPath("sourceReleaseJar").duplicatesStrategy = DuplicatesStrategy.EXCLUDE
}