mirror of
https://github.com/recloudstream/cloudstream.git
synced 2024-08-15 01:53:11 +00:00
updated repo constants
This commit is contained in:
parent
069808ca72
commit
d402568d50
5 changed files with 11 additions and 8 deletions
2
.github/ISSUE_TEMPLATE/application-bug.yml
vendored
2
.github/ISSUE_TEMPLATE/application-bug.yml
vendored
|
@ -75,7 +75,7 @@ body:
|
||||||
required: true
|
required: true
|
||||||
- label: I have written a short but informative title.
|
- label: I have written a short but informative title.
|
||||||
required: true
|
required: true
|
||||||
- label: I have updated the app to pre-release version **[Latest](https://github.com/LagradOst/CloudStream-3/releases)**.
|
- label: I have updated the app to pre-release version **[Latest](https://github.com/rereleased/release/releases)**.
|
||||||
required: true
|
required: true
|
||||||
- label: If related to a provider, I have checked the site and it works, but not the app.
|
- label: If related to a provider, I have checked the site and it works, but not the app.
|
||||||
required: true
|
required: true
|
||||||
|
|
|
@ -371,7 +371,7 @@ object APIHolder {
|
||||||
*/
|
*/
|
||||||
const val PROVIDER_STATUS_KEY = "PROVIDER_STATUS_KEY"
|
const val PROVIDER_STATUS_KEY = "PROVIDER_STATUS_KEY"
|
||||||
const val PROVIDER_STATUS_URL =
|
const val PROVIDER_STATUS_URL =
|
||||||
"https://raw.githubusercontent.com/LagradOst/CloudStream-3/master/docs/providers.json"
|
"https://raw.githubusercontent.com/reduplicated/Cloudstream/master/docs/providers.json"
|
||||||
const val PROVIDER_STATUS_BETA_ONLY = 3
|
const val PROVIDER_STATUS_BETA_ONLY = 3
|
||||||
const val PROVIDER_STATUS_SLOW = 2
|
const val PROVIDER_STATUS_SLOW = 2
|
||||||
const val PROVIDER_STATUS_OK = 1
|
const val PROVIDER_STATUS_OK = 1
|
||||||
|
|
|
@ -29,7 +29,7 @@ class WcoHelper {
|
||||||
private var newKeys: NewExternalKeys? = null
|
private var newKeys: NewExternalKeys? = null
|
||||||
private suspend fun getKeys() {
|
private suspend fun getKeys() {
|
||||||
keys = keys
|
keys = keys
|
||||||
?: app.get("https://raw.githubusercontent.com/LagradOst/CloudStream-3/master/docs/keys.json")
|
?: app.get("https://raw.githubusercontent.com/reduplicated/Cloudstream/master/docs/keys.json")
|
||||||
.parsedSafe<ExternalKeys>()?.also { setKey(BACKUP_KEY_DATA, it) } ?: getKey(
|
.parsedSafe<ExternalKeys>()?.also { setKey(BACKUP_KEY_DATA, it) } ?: getKey(
|
||||||
BACKUP_KEY_DATA
|
BACKUP_KEY_DATA
|
||||||
)
|
)
|
||||||
|
|
|
@ -31,6 +31,9 @@ import kotlin.concurrent.thread
|
||||||
|
|
||||||
class InAppUpdater {
|
class InAppUpdater {
|
||||||
companion object {
|
companion object {
|
||||||
|
const val GITHUB_USER_NAME = "rereleased"
|
||||||
|
const val GITHUB_REPO = "release"
|
||||||
|
|
||||||
// === IN APP UPDATER ===
|
// === IN APP UPDATER ===
|
||||||
data class GithubAsset(
|
data class GithubAsset(
|
||||||
@JsonProperty("name") val name: String,
|
@JsonProperty("name") val name: String,
|
||||||
|
@ -81,7 +84,7 @@ class InAppUpdater {
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun Activity.getReleaseUpdate(): Update {
|
private fun Activity.getReleaseUpdate(): Update {
|
||||||
val url = "https://api.github.com/repos/LagradOst/CloudStream-3/releases"
|
val url = "https://api.github.com/repos/$GITHUB_USER_NAME/$GITHUB_REPO/releases"
|
||||||
val headers = mapOf("Accept" to "application/vnd.github.v3+json")
|
val headers = mapOf("Accept" to "application/vnd.github.v3+json")
|
||||||
val response =
|
val response =
|
||||||
parseJson<List<GithubRelease>>(runBlocking {
|
parseJson<List<GithubRelease>>(runBlocking {
|
||||||
|
@ -148,8 +151,8 @@ class InAppUpdater {
|
||||||
|
|
||||||
private fun Activity.getPreReleaseUpdate(): Update = runBlocking {
|
private fun Activity.getPreReleaseUpdate(): Update = runBlocking {
|
||||||
val tagUrl =
|
val tagUrl =
|
||||||
"https://api.github.com/repos/LagradOst/CloudStream-3/git/ref/tags/pre-release"
|
"https://api.github.com/repos/$GITHUB_USER_NAME/$GITHUB_REPO/git/ref/tags/pre-release"
|
||||||
val releaseUrl = "https://api.github.com/repos/LagradOst/CloudStream-3/releases"
|
val releaseUrl = "https://api.github.com/repos/$GITHUB_USER_NAME/$GITHUB_REPO/releases"
|
||||||
val headers = mapOf("Accept" to "application/vnd.github.v3+json")
|
val headers = mapOf("Accept" to "application/vnd.github.v3+json")
|
||||||
val response =
|
val response =
|
||||||
parseJson<List<GithubRelease>>(app.get(releaseUrl, headers = headers).text)
|
parseJson<List<GithubRelease>>(app.get(releaseUrl, headers = headers).text)
|
||||||
|
|
|
@ -26,10 +26,10 @@
|
||||||
<Preference
|
<Preference
|
||||||
android:title="@string/github"
|
android:title="@string/github"
|
||||||
android:icon="@drawable/ic_github_logo"
|
android:icon="@drawable/ic_github_logo"
|
||||||
app:summary="https://github.com/LagradOst/CloudStream-3">
|
app:summary="https://github.com/rereleased/release/releases">
|
||||||
<intent
|
<intent
|
||||||
android:action="android.intent.action.VIEW"
|
android:action="android.intent.action.VIEW"
|
||||||
android:data="https://github.com/LagradOst/CloudStream-3" />
|
android:data="https://github.com/rereleased/release/releases" />
|
||||||
</Preference>
|
</Preference>
|
||||||
|
|
||||||
<Preference
|
<Preference
|
||||||
|
|
Loading…
Reference in a new issue