libsignal-service-java/libsignal-service-java.patch

161 lines
5.5 KiB
Diff
Raw Normal View History

2021-11-08 23:47:39 +00:00
From 679a423f659506e1dc3b597bb940eb5c9c12b02f Mon Sep 17 00:00:00 2001
From: nobody <nobody@signald.org>
Date: Mon, 8 Nov 2021 15:46:59 -0800
2021-10-27 02:46:14 +00:00
Subject: [PATCH] update gradle files
2021-10-27 01:01:41 +00:00
---
2021-11-08 23:18:19 +00:00
build.gradle | 10 +-------
2021-11-08 23:10:46 +00:00
dependencies.gradle | 6 ++---
2021-11-08 23:47:39 +00:00
service/build.gradle | 57 ++++++++------------------------------------
2021-10-27 01:01:41 +00:00
settings.gradle | 2 --
2021-11-08 23:47:39 +00:00
4 files changed, 13 insertions(+), 62 deletions(-)
2021-10-27 01:01:41 +00:00
diff --git a/build.gradle b/build.gradle
2021-11-08 23:47:39 +00:00
index 623f06c..785dbcc 100644
2021-10-27 01:01:41 +00:00
--- a/build.gradle
+++ b/build.gradle
2021-11-08 23:47:39 +00:00
@@ -1,5 +1,6 @@
buildscript {
2021-11-08 23:18:19 +00:00
repositories {
2021-11-08 23:47:39 +00:00
+ maven {url "https://gitlab.com/api/v4/groups/6853927/-/packages/maven"} // https://gitlab.com/groups/signald/-/packages
2021-11-08 23:18:19 +00:00
google()
mavenCentral()
}
@@ -23,15 +24,6 @@ def getRepositoryPassword() {
2021-10-27 02:46:14 +00:00
return hasProperty('whisperSonatypePassword') ? whisperSonatypePassword : ""
2021-10-27 01:01:41 +00:00
}
2021-10-27 02:46:14 +00:00
-nexusPublishing {
- repositories {
- sonatype {
- username = getRepositoryUsername()
- password = getRepositoryPassword()
- }
- }
-}
-
subprojects {
2021-11-08 23:47:39 +00:00
ext.lib_signal_service_version_number = "2.15.3_unofficial_32"
2021-10-27 02:46:14 +00:00
ext.lib_signal_service_group_info = "com.github.turasa"
2021-10-27 01:01:41 +00:00
diff --git a/dependencies.gradle b/dependencies.gradle
2021-11-08 23:47:39 +00:00
index a046f96..01adfb6 100644
2021-10-27 01:01:41 +00:00
--- a/dependencies.gradle
+++ b/dependencies.gradle
2021-11-08 23:10:46 +00:00
@@ -9,10 +9,8 @@ dependencyResolutionManagement {
2021-11-08 23:47:39 +00:00
alias('google-libphonenumber').to('com.googlecode.libphonenumber:libphonenumber:8.12.33')
2021-10-27 01:01:41 +00:00
// 1st Party
2021-11-08 23:10:46 +00:00
- alias('signal-client-java').to('org.whispersystems', 'signal-client-java').versionRef('signal-client')
2021-10-27 02:46:14 +00:00
- alias('signal-client-android').to('org.whispersystems', 'signal-client-android').versionRef('signal-client')
2021-11-08 23:10:46 +00:00
- alias('signal-zkgroup-java').to('org.signal', 'zkgroup-java').versionRef('zkgroup')
2021-10-27 02:46:14 +00:00
- alias('signal-zkgroup-android').to('org.signal', 'zkgroup-android').versionRef('zkgroup')
2021-11-08 23:10:46 +00:00
+ alias('signal-client-java').to('org.whispersystems', 'signal-client-java-' + System.getenv("TARGET")).versionRef('signal-client')
+ alias('signal-zkgroup-java').to('org.signal', 'zkgroup-java-' + System.getenv("TARGET")).versionRef('zkgroup')
2021-10-27 01:01:41 +00:00
// Third Party
2021-10-27 02:46:14 +00:00
alias('jackson-core').to('com.fasterxml.jackson.core:jackson-databind:2.9.9.2')
2021-10-27 01:01:41 +00:00
diff --git a/service/build.gradle b/service/build.gradle
2021-11-08 23:47:39 +00:00
index e354777..399b27c 100644
2021-10-27 01:01:41 +00:00
--- a/service/build.gradle
+++ b/service/build.gradle
2021-11-08 23:47:39 +00:00
@@ -23,6 +23,7 @@ compileJava {
}
repositories {
2021-11-08 23:47:39 +00:00
+ maven {url "https://gitlab.com/api/v4/groups/6853927/-/packages/maven"} // https://gitlab.com/groups/signald/-/packages
mavenCentral()
mavenLocal()
2021-11-08 23:47:39 +00:00
}
@@ -91,8 +92,7 @@ def isReleaseBuild() {
}
2021-11-08 23:47:39 +00:00
def getReleaseRepositoryUrl() {
- return hasProperty('sonatypeRepo') ? sonatypeRepo
- : "https://oss.sonatype.org/service/local/staging/deploy/maven2/"
+ return System.getenv("CI_API_V4_URL") + "/projects/" + System.getenv("CI_PROJECT_ID") + "/packages/maven"
}
def getRepositoryUsername() {
@@ -105,58 +105,21 @@ def getRepositoryPassword() {
2021-10-27 01:01:41 +00:00
publishing {
publications {
- mavenJava(MavenPublication) {
- artifactId = 'signal-service-java'
2021-11-08 23:47:39 +00:00
- from components.java
2021-10-27 01:01:41 +00:00
-
- pom {
- name = 'signal-service-java'
- packaging = 'jar'
- description = 'Signal Service communication library for Java, unofficial fork'
- url = 'https://github.com/Turasa/libsignal-service-java'
-
- scm {
- url = 'scm:git@github.com:Turasa/libsignal-service-java.git'
- connection = 'scm:git@github.com:Turasa/libsignal-service-java.git'
- developerConnection = 'scm:git@github.com:Turasa/libsignal-service-java.git'
- }
-
- licenses {
- license {
- name = 'GPLv3'
- url = 'https://www.gnu.org/licenses/gpl-3.0.txt'
- distribution = 'repo'
- }
- }
-
- developers {
- developer {
- name = 'Moxie Marlinspike'
- }
- developer {
- name = 'Sebastian Scheibner'
- }
- developer {
- name = 'Tilman Hoffbauer'
- }
- }
- }
-
2021-11-08 23:47:39 +00:00
+ library(MavenPublication) {
2021-10-27 01:01:41 +00:00
+ artifactId = archivesBaseName + "-" + System.getenv("TARGET")
}
}
2021-11-08 23:47:39 +00:00
2021-10-27 01:01:41 +00:00
repositories {
maven {
2021-11-08 23:47:39 +00:00
url = getReleaseRepositoryUrl()
2021-10-27 01:01:41 +00:00
- credentials {
- username getRepositoryUsername()
- password getRepositoryPassword()
+ credentials(HttpHeaderCredentials) {
+ name = 'Job-Token'
+ value = System.getenv("CI_JOB_TOKEN")
+ }
+ authentication {
+ header(HttpHeaderAuthentication)
}
}
}
2021-10-27 02:46:14 +00:00
}
2021-10-27 01:01:41 +00:00
-
-signing {
- required { isReleaseBuild() && gradle.taskGraph.hasTask("uploadArchives") }
- sign publishing.publications.mavenJava
-}
diff --git a/settings.gradle b/settings.gradle
index 8861c00..4048aab 100644
--- a/settings.gradle
+++ b/settings.gradle
@@ -1,7 +1,5 @@
enableFeaturePreview('VERSION_CATALOGS')
-include ':android'
-
include 'libsignal-service'
project(':libsignal-service').projectDir = file('service')
--
2.20.1