All checks were successful
Build four ZaStoGram APKs / build (arm64-v8a, ZaStoGram-standalone-arm64-v8a, Arm64, arm64) (push) Successful in 8m19s
Build four ZaStoGram APKs / build (armeabi-v7a, ZaStoGram-standalone-armeabi-v7a, Armv7, armv7) (push) Successful in 8m1s
Build four ZaStoGram APKs / build (x86, ZaStoGram-standalone-x86, X86, x86) (push) Successful in 8m36s
Build four ZaStoGram APKs / build (x86_64, ZaStoGram-standalone-x86_64, X64, x64) (push) Successful in 7m54s
ZaStoGram source guards / guards (push) Successful in 12s
45 lines
2.4 KiB
Groovy
45 lines
2.4 KiB
Groovy
// Top-level build file where you can add configuration options common to all sub-projects/modules.
|
|
buildscript {
|
|
repositories {
|
|
mavenCentral()
|
|
google()
|
|
maven { url 'https://developer.huawei.com/repo/' }
|
|
}
|
|
dependencies {
|
|
classpath 'com.android.tools.build:gradle:8.6.1'
|
|
classpath 'com.google.gms:google-services:4.3.15'
|
|
classpath 'com.huawei.agconnect:agcp:1.9.1.301'
|
|
classpath 'com.google.firebase:firebase-crashlytics-gradle:2.9.0'
|
|
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.9.20"
|
|
// ZaStoGram plugin engine: Chaquopy embeds CPython 3.11 into the APK.
|
|
// 16.1.x supports AGP 7.0-8.13 (we use 8.6.1) and Python 3.8-3.13.
|
|
classpath 'com.chaquo.python:gradle:16.1.0'
|
|
}
|
|
}
|
|
repositories {
|
|
google()
|
|
}
|
|
|
|
// ZaStoGram release identity is a single build-wide input. The standalone
|
|
// application derives both its install identity and updater channel from these
|
|
// values, so a dev APK can never accidentally replace the stable application.
|
|
def zastoUpdateChannelValue = (findProperty("zastoUpdateChannel") ?: System.getenv("ZASTO_UPDATE_CHANNEL") ?: "stable").toString().trim().toLowerCase()
|
|
if (!(zastoUpdateChannelValue in ["dev", "stable"])) {
|
|
throw new GradleException("Unsupported ZaStoGram update channel '${zastoUpdateChannelValue}'. Expected dev or stable")
|
|
}
|
|
def zastoReleaseTagValue = (findProperty("zastoReleaseTag") ?: System.getenv("ZASTO_RELEASE_TAG") ?: "").toString().trim()
|
|
def zastoForgejoRepositoryValue = (findProperty("zastoForgejoRepository") ?: System.getenv("ZASTO_FORGEJO_REPOSITORY") ?: "zapretdiscordyoutube/ZaStoGram").toString().trim()
|
|
if (!(zastoForgejoRepositoryValue ==~ /[A-Za-z0-9_.-]+\/[A-Za-z0-9_.-]+/)) {
|
|
throw new GradleException("Invalid ZaStoGram Forgejo repository '${zastoForgejoRepositoryValue}'. Expected owner/repository")
|
|
}
|
|
def zastoBuildNumberValue = (findProperty("zastoBuildNumber") ?: System.getenv("ZASTO_BUILD_NUMBER") ?: "0").toString().trim()
|
|
if (!(zastoBuildNumberValue ==~ /\d+/) || zastoBuildNumberValue.toInteger() > 9999) {
|
|
throw new GradleException("Invalid ZaStoGram build number '${zastoBuildNumberValue}'. Expected an integer from 0 to 9999")
|
|
}
|
|
|
|
ext.zastoReleaseIdentity = [
|
|
updateChannel: zastoUpdateChannelValue,
|
|
releaseTag: zastoReleaseTagValue,
|
|
forgejoRepository: zastoForgejoRepositoryValue,
|
|
buildNumber: zastoBuildNumberValue.toInteger(),
|
|
]
|