Bump app version and use static contributors

Replace HTTP contributors API call with a curated static list of GitHub
usernames and avatar URLs to avoid depending on a specific repo. Update
versionCode to 100030 and versionName to 1.0.3
This commit is contained in:
kmmiio99o 2025-10-25 20:58:53 +02:00
parent 8bd35d6e68
commit ad877dd434
2 changed files with 34 additions and 10 deletions

View file

@ -24,8 +24,8 @@ android {
defaultConfig {
minSdk = 28
targetSdk = 36
versionCode = 10_00_20
versionName = "1.0.2"
versionCode = 10_00_30
versionName = "1.0.3"
vectorDrawables {
useSupportLibrary = true
}

View file

@ -8,6 +8,9 @@ import com.aliucord.manager.network.utils.fold
import com.aliucord.manager.ui.util.toUnsafeImmutable
import com.aliucord.manager.util.launchIO
import io.ktor.client.request.url
import kotlinx.serialization.Serializable
import kotlinx.serialization.SerialName
import kotlinx.collections.immutable.persistentListOf
class AboutModel(
private val http: HttpService,
@ -19,15 +22,36 @@ class AboutModel(
fun fetchContributors() = screenModelScope.launchIO {
mutableState.value = AboutScreenState.Loading
val response = http.request<List<Contributor>> { url(CONTRIBUTORS_API_URL) }
mutableState.value = response.fold(
success = { AboutScreenState.Loaded(it.toUnsafeImmutable()) },
fail = { AboutScreenState.Failure },
// Use a curated static list of GitHub usernames (profiles + static avatar URLs).
// This avoids pulling from a specific repo and lets us include people
// who are not contributors to any particular repository.
val staticContributors = persistentListOf(
Contributor(
username = "rushiiMachine",
avatarUrl = "https://github.com/rushiiMachine.png",
commits = 0,
repositories = persistentListOf<com.aliucord.manager.network.models.Contributor.Repository>()
),
Contributor(
username = "maisymoe",
avatarUrl = "https://github.com/maisymoe.png",
commits = 0,
repositories = persistentListOf<com.aliucord.manager.network.models.Contributor.Repository>()
),
Contributor(
username = "kmmiio99o",
avatarUrl = "https://github.com/kmmiio99o.png",
commits = 0,
repositories = persistentListOf<com.aliucord.manager.network.models.Contributor.Repository>()
),
Contributor(
username = "pylixonly",
avatarUrl = "https://github.com/pylixonly.png",
commits = 0,
repositories = persistentListOf<com.aliucord.manager.network.models.Contributor.Repository>()
)
)
}
companion object {
private const val CONTRIBUTORS_API_URL = "https://api.rushii.dev/aliucord/contributors"
mutableState.value = AboutScreenState.Loaded(staticContributors.toUnsafeImmutable())
}
}