Revert "Update to extensions-lib 1.3 (#11298)"
This reverts commit 67263a106b
.
This commit is contained in:
parent
c79d082d3b
commit
f94099b8e8
|
@ -31,7 +31,7 @@ jobs:
|
|||
- name: Set up JDK
|
||||
uses: actions/setup-java@v1
|
||||
with:
|
||||
java-version: 11
|
||||
java-version: 1.8
|
||||
|
||||
- name: Copy CI gradle.properties
|
||||
run: |
|
||||
|
@ -70,7 +70,7 @@ jobs:
|
|||
- name: Set up JDK
|
||||
uses: actions/setup-java@v1
|
||||
with:
|
||||
java-version: 11
|
||||
java-version: 1.8
|
||||
|
||||
- name: Copy CI gradle.properties
|
||||
run: |
|
||||
|
|
|
@ -39,7 +39,7 @@ jobs:
|
|||
- name: Set up JDK
|
||||
uses: actions/setup-java@v1
|
||||
with:
|
||||
java-version: 11
|
||||
java-version: 1.8
|
||||
|
||||
- name: Copy CI files
|
||||
run: |
|
||||
|
@ -93,7 +93,7 @@ jobs:
|
|||
- name: Set up JDK
|
||||
uses: actions/setup-java@v1
|
||||
with:
|
||||
java-version: 11
|
||||
java-version: 1.8
|
||||
|
||||
- name: Copy CI files
|
||||
run: |
|
||||
|
|
|
@ -93,7 +93,7 @@ apply from: "$rootDir/common.gradle"
|
|||
| `pkgNameSuffix` | A unique suffix added to `eu.kanade.tachiyomi.extension`. The language and the site name should be enough. Remember your extension code implementation must be placed in this package. |
|
||||
| `extClass` | Points to the class that implements `Source`. You can use a relative path starting with a dot (the package name is the base path). This is used to find and instantiate the source(s). |
|
||||
| `extVersionCode` | The extension version code. This must be a positive integer and incremented with any change to the code. |
|
||||
| `libVersion` | (Optional, defaults to `1.3`) The version of the [extensions library](https://github.com/tachiyomiorg/extensions-lib) used. |
|
||||
| `libVersion` | (Optional, defaults to `1.2`) The version of the [extensions library](https://github.com/tachiyomiorg/extensions-lib) used. |
|
||||
| `isNsfw` | (Optional, defaults to `false`) Flag to indicate that a source contains NSFW content. |
|
||||
|
||||
The extension's version name is generated automatically by concatenating `libVersion` and `extVersionCode`. With the example used above, the version would be `1.2.1`.
|
||||
|
|
|
@ -22,7 +22,7 @@ android {
|
|||
targetSdkVersion AndroidConfig.targetSdk
|
||||
applicationIdSuffix pkgNameSuffix
|
||||
versionCode extVersionCode
|
||||
versionName project.ext.properties.getOrDefault("libVersion", "1.3") + ".$extVersionCode"
|
||||
versionName project.ext.properties.getOrDefault("libVersion", "1.2") + ".$extVersionCode"
|
||||
setProperty("archivesBaseName", "tachiyomi-$pkgNameSuffix-v$versionName")
|
||||
def readmes = project.projectDir.listFiles({ File file ->
|
||||
file.name.equals("README.md") ||
|
||||
|
|
|
@ -1,32 +1,29 @@
|
|||
[versions]
|
||||
kotlin_version = "1.6.10"
|
||||
coroutines_version = "1.6.0"
|
||||
serialization_version = "1.3.2"
|
||||
kotlin_version = "1.4.32"
|
||||
coroutines_version = "1.4.3"
|
||||
|
||||
[libraries]
|
||||
gradle-agp = { module = "com.android.tools.build:gradle", version = "7.1.2" }
|
||||
gradle-agp = { module = "com.android.tools.build:gradle", version = "4.2.1" }
|
||||
gradle-kotlin = { module = "org.jetbrains.kotlin:kotlin-gradle-plugin", version.ref = "kotlin_version" }
|
||||
gradle-serialization = { module = "org.jetbrains.kotlin:kotlin-serialization", version.ref = "kotlin_version" }
|
||||
gradle-kotlinter = { module = "org.jmailen.gradle:kotlinter-gradle", version = "3.6.0" }
|
||||
gradle-kotlinter = { module = "org.jmailen.gradle:kotlinter-gradle", version = "3.4.0" }
|
||||
|
||||
tachiyomi-lib = { module = "com.github.tachiyomiorg:extensions-lib", version = "1.3.1" }
|
||||
tachiyomi-lib = { module = "com.github.tachiyomiorg:extensions-lib", version = "58b2d3a" }
|
||||
|
||||
kotlin-stdlib = { module = "org.jetbrains.kotlin:kotlin-stdlib-jdk8", version.ref = "kotlin_version" }
|
||||
kotlin-protobuf = { module = "org.jetbrains.kotlinx:kotlinx-serialization-protobuf", version.ref = "serialization_version" }
|
||||
kotlin-json = { module = "org.jetbrains.kotlinx:kotlinx-serialization-json", version.ref = "serialization_version" }
|
||||
kotlin-protobuf = { module = "org.jetbrains.kotlinx:kotlinx-serialization-protobuf", version = "1.2.0" }
|
||||
kotlin-json = { module = "org.jetbrains.kotlinx:kotlinx-serialization-json", version = "1.2.0" }
|
||||
|
||||
coroutines-core = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-core", version.ref = "coroutines_version" }
|
||||
coroutines-android = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-android", version.ref = "coroutines_version" }
|
||||
|
||||
injekt-core = { module = "com.github.inorichi.injekt:injekt-core", version = "65b0440" }
|
||||
jsoup = { module = "org.jsoup:jsoup", version = "1.13.1" }
|
||||
duktape = { module = "com.squareup.duktape:duktape-android", version = "1.4.0" }
|
||||
quickjs = { module = "app.cash.quickjs:quickjs-android", version = "0.9.2" }
|
||||
okhttp = { module = "com.squareup.okhttp3:okhttp", version = "4.9.1" }
|
||||
rxandroid = { module = "io.reactivex:rxandroid", version = "1.2.1" }
|
||||
rxjava = { module = "io.reactivex:rxjava", version = "1.3.8" }
|
||||
|
||||
[bundles]
|
||||
common = ["kotlin-stdlib", "injekt-core", "rxjava", "kotlin-protobuf", "kotlin-json", "jsoup", "okhttp", "tachiyomi-lib", "duktape", "quickjs"]
|
||||
common = ["tachiyomi-lib", "jsoup", "okhttp", "kotlin-stdlib", "injekt-core", "rxjava", "kotlin-protobuf", "kotlin-json"]
|
||||
coroutines = ["coroutines-core", "coroutines-android"]
|
||||
reactivex = ["rxandroid"]
|
||||
|
|
|
@ -20,12 +20,6 @@ repositories {
|
|||
mavenCentral()
|
||||
}
|
||||
|
||||
configurations {
|
||||
compileOnly {
|
||||
isCanBeResolved = true
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
compileOnly(libs.bundles.common)
|
||||
}
|
||||
|
@ -34,8 +28,7 @@ tasks {
|
|||
val generateExtensions by registering {
|
||||
doLast {
|
||||
val isWindows = System.getProperty("os.name").toString().toLowerCase().contains("win")
|
||||
var classPath = (
|
||||
configurations.compileOnly.get().asFileTree.toList() +
|
||||
var classPath = (configurations.debugCompileOnly.get().asFileTree.toList() +
|
||||
listOf(
|
||||
configurations.androidApis.get().asFileTree.first().absolutePath, // android.jar path
|
||||
"$projectDir/build/intermediates/aar_main_jar/debug/classes.jar" // jar made from this module
|
||||
|
|
|
@ -77,8 +77,8 @@ class Manhwa18 : FMReader("Manhwa18", "https://manhwa18.com", "en") {
|
|||
name = element.attr("title")
|
||||
date_upload =
|
||||
SimpleDateFormat("dd/MM/yyyy", Locale.US).parse(
|
||||
element.select(".chapter-time").text().substringAfter(" - ")
|
||||
)?.time ?: 0L
|
||||
element.select(".chapter-time").text().substringAfter(" - ")
|
||||
)?.time ?: 0L
|
||||
chapter_number = element.attr("time").substringAfterLast(' ').toFloatOrNull() ?: -1f
|
||||
}
|
||||
}
|
||||
|
|
|
@ -3,7 +3,7 @@ package eu.kanade.tachiyomi.extension.all.foolslidecustomizable
|
|||
import android.widget.Toast
|
||||
import androidx.preference.EditTextPreference
|
||||
import androidx.preference.PreferenceScreen
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.BuildConfig
|
||||
import eu.kanade.tachiyomi.multisrc.foolslide.FoolSlide
|
||||
import eu.kanade.tachiyomi.source.SourceFactory
|
||||
|
||||
|
@ -42,7 +42,7 @@ class FoolSlideCustomizable : FoolSlide("FoolSlide Customizable", "", "other") {
|
|||
companion object {
|
||||
private const val DEFAULT_BASEURL = "https://127.0.0.1"
|
||||
private const val BASE_URL_PREF_TITLE = "Example URL: https://domain.com/path_to/directory/"
|
||||
private val BASE_URL_PREF = "overrideBaseUrl_v${AppInfo.getVersionName()}"
|
||||
private val BASE_URL_PREF = "overrideBaseUrl_v${BuildConfig.VERSION_NAME}"
|
||||
private const val BASE_URL_PREF_SUMMARY = "Connect to a designated FoolSlide server"
|
||||
private const val RESTART_TACHIYOMI = "Restart Tachiyomi to apply new setting."
|
||||
}
|
||||
|
|
|
@ -5,7 +5,7 @@ import android.content.SharedPreferences
|
|||
import android.widget.Toast
|
||||
import androidx.preference.EditTextPreference
|
||||
import androidx.preference.PreferenceScreen
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.BuildConfig
|
||||
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
|
||||
import eu.kanade.tachiyomi.multisrc.madara.Madara
|
||||
import eu.kanade.tachiyomi.network.GET
|
||||
|
@ -231,7 +231,7 @@ class NeoxScanlator :
|
|||
private const val REFERER = "https://google.com/"
|
||||
|
||||
private const val DEFAULT_BASE_URL = "https://neoxscans.net"
|
||||
private val BASE_URL_PREF_KEY = "base_url_${AppInfo.getVersionName()}"
|
||||
private val BASE_URL_PREF_KEY = "base_url_${BuildConfig.VERSION_NAME}"
|
||||
private const val BASE_URL_PREF_TITLE = "URL da fonte"
|
||||
private const val BASE_URL_PREF_SUMMARY = "Para uso temporário. Quando você atualizar a " +
|
||||
"extensão, esta configuração será apagada."
|
||||
|
|
|
@ -4,7 +4,7 @@ import android.app.Application
|
|||
import android.os.Build
|
||||
import androidx.preference.ListPreference
|
||||
import androidx.preference.PreferenceScreen
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.BuildConfig
|
||||
import eu.kanade.tachiyomi.network.GET
|
||||
import eu.kanade.tachiyomi.network.asObservableSuccess
|
||||
import eu.kanade.tachiyomi.source.ConfigurableSource
|
||||
|
@ -31,7 +31,7 @@ abstract class BakkinReaderX(
|
|||
|
||||
private val userAgent = "Mozilla/5.0 (" +
|
||||
"Android ${Build.VERSION.RELEASE}; Mobile) " +
|
||||
"Tachiyomi/${AppInfo.getVersionName()}"
|
||||
"Tachiyomi/${BuildConfig.VERSION_NAME}"
|
||||
|
||||
protected val preferences by lazy {
|
||||
Injekt.get<Application>().getSharedPreferences("source_$id", 0x0000)!!
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
package eu.kanade.tachiyomi.multisrc.comicake
|
||||
|
||||
import android.os.Build
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.BuildConfig
|
||||
import eu.kanade.tachiyomi.network.GET
|
||||
import eu.kanade.tachiyomi.network.asObservableSuccess
|
||||
import eu.kanade.tachiyomi.source.model.FilterList
|
||||
|
@ -34,7 +34,7 @@ abstract class ComiCake(
|
|||
|
||||
private val userAgent = "Mozilla/5.0 (" +
|
||||
"Android ${Build.VERSION.RELEASE}; Mobile) " +
|
||||
"Tachiyomi/${AppInfo.getVersionName()}"
|
||||
"Tachiyomi/${BuildConfig.VERSION_NAME}"
|
||||
|
||||
override fun headersBuilder() = Headers.Builder().apply {
|
||||
add("User-Agent", userAgent)
|
||||
|
|
|
@ -5,7 +5,7 @@ import android.content.SharedPreferences
|
|||
import android.os.Build
|
||||
import androidx.preference.ListPreference
|
||||
import androidx.preference.PreferenceScreen
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.BuildConfig
|
||||
import eu.kanade.tachiyomi.network.GET
|
||||
import eu.kanade.tachiyomi.network.asObservable
|
||||
import eu.kanade.tachiyomi.network.asObservableSuccess
|
||||
|
@ -40,7 +40,7 @@ abstract class Guya(
|
|||
"User-Agent",
|
||||
"(Android ${Build.VERSION.RELEASE}; " +
|
||||
"${Build.MANUFACTURER} ${Build.MODEL}) " +
|
||||
"Tachiyomi/${AppInfo.getVersionName()} ${Build.ID}"
|
||||
"Tachiyomi/${BuildConfig.VERSION_NAME} ${Build.ID}"
|
||||
)
|
||||
|
||||
private val scanlators: ScanlatorStore = ScanlatorStore()
|
||||
|
|
|
@ -2,7 +2,7 @@ package eu.kanade.tachiyomi.multisrc.mangadventure
|
|||
|
||||
import android.net.Uri
|
||||
import android.os.Build.VERSION
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.BuildConfig
|
||||
import eu.kanade.tachiyomi.network.GET
|
||||
import eu.kanade.tachiyomi.network.asObservableSuccess
|
||||
import eu.kanade.tachiyomi.source.model.FilterList
|
||||
|
@ -36,7 +36,7 @@ abstract class MangAdventure(
|
|||
/** A user agent representing Tachiyomi. */
|
||||
private val userAgent = "Mozilla/5.0 " +
|
||||
"(Android ${VERSION.RELEASE}; Mobile) " +
|
||||
"Tachiyomi/${AppInfo.getVersionName()}"
|
||||
"Tachiyomi/${BuildConfig.VERSION_NAME}"
|
||||
|
||||
/** The URI of the site's API. */
|
||||
private val apiUri by lazy {
|
||||
|
|
|
@ -2,7 +2,7 @@ package eu.kanade.tachiyomi.extension.all.cubari
|
|||
|
||||
import android.app.Application
|
||||
import android.os.Build
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.BuildConfig
|
||||
import eu.kanade.tachiyomi.network.GET
|
||||
import eu.kanade.tachiyomi.network.asObservableSuccess
|
||||
import eu.kanade.tachiyomi.source.model.FilterList
|
||||
|
@ -42,7 +42,7 @@ open class Cubari(override val lang: String) : HttpSource() {
|
|||
"User-Agent",
|
||||
"(Android ${Build.VERSION.RELEASE}; " +
|
||||
"${Build.MANUFACTURER} ${Build.MODEL}) " +
|
||||
"Tachiyomi/${AppInfo.getVersionName()} " +
|
||||
"Tachiyomi/${BuildConfig.VERSION_NAME} " +
|
||||
Build.ID
|
||||
)
|
||||
}
|
||||
|
|
|
@ -358,7 +358,7 @@ open class Hitomi(override val lang: String, private val nozomiLang: String) : H
|
|||
gg = response.body!!.string()
|
||||
}
|
||||
val duktape = Duktape.create()
|
||||
duktape.evaluate(gg!!)
|
||||
duktape.evaluate(gg)
|
||||
|
||||
val str = response.body!!.string()
|
||||
val json = json.decodeFromString<HitomiChapterDto>(str.removePrefix("var galleryinfo = "))
|
||||
|
|
|
@ -7,7 +7,7 @@ import android.util.Log
|
|||
import android.widget.Toast
|
||||
import androidx.preference.EditTextPreference
|
||||
import androidx.preference.MultiSelectListPreference
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.BuildConfig
|
||||
import eu.kanade.tachiyomi.extension.all.kavita.dto.AuthenticationDto
|
||||
import eu.kanade.tachiyomi.extension.all.kavita.dto.ChapterDto
|
||||
import eu.kanade.tachiyomi.extension.all.kavita.dto.MangaFormat
|
||||
|
@ -859,13 +859,13 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, HttpSource()
|
|||
override fun headersBuilder(): Headers.Builder {
|
||||
if (jwtToken.isEmpty()) throw LoginErrorException("401 Error\nOPDS address got modified or is incorrect")
|
||||
return Headers.Builder()
|
||||
.add("User-Agent", "Tachiyomi Kavita v${AppInfo.getVersionName()}")
|
||||
.add("User-Agent", "Tachiyomi Kavita v${BuildConfig.VERSION_NAME}")
|
||||
.add("Content-Type", "application/json")
|
||||
.add("Authorization", "Bearer $jwtToken")
|
||||
}
|
||||
private fun setupLoginHeaders(): Headers.Builder {
|
||||
return Headers.Builder()
|
||||
.add("User-Agent", "Tachiyomi Kavita v${AppInfo.getVersionName()}")
|
||||
.add("User-Agent", "Tachiyomi Kavita v${BuildConfig.VERSION_NAME}")
|
||||
.add("Content-Type", "application/json")
|
||||
.add("Authorization", "Bearer $jwtToken")
|
||||
}
|
||||
|
@ -1147,13 +1147,13 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, HttpSource()
|
|||
.parseAs<ServerInfoDto>()
|
||||
Log.e(
|
||||
LOG_TAG,
|
||||
"Extension version: code=${AppInfo.getVersionCode()} name=${AppInfo.getVersionName()}" +
|
||||
"Extension version: code=${BuildConfig.VERSION_CODE} name=${BuildConfig.VERSION_NAME}" +
|
||||
" - - Kavita version: ${serverInfoDto.kavitaVersion}"
|
||||
) // this is not a real error. Using this so it gets printed in dump logs if there's any error
|
||||
} catch (e: EmptyRequestBody) {
|
||||
Log.e(LOG_TAG, "Extension version: code=${AppInfo.getVersionCode()} - name=${AppInfo.getVersionName()}")
|
||||
Log.e(LOG_TAG, "Extension version: code=${BuildConfig.VERSION_CODE} - name=${BuildConfig.VERSION_NAME}")
|
||||
} catch (e: Exception) {
|
||||
Log.e(LOG_TAG, "Tachiyomi version: code=${AppInfo.getVersionCode()} - name=${AppInfo.getVersionName()}", e)
|
||||
Log.e(LOG_TAG, "Tachiyomi version: code=${BuildConfig.VERSION_CODE} - name=${BuildConfig.VERSION_NAME}", e)
|
||||
}
|
||||
try { // Load Filters
|
||||
// Genres
|
||||
|
|
|
@ -5,7 +5,7 @@ import android.content.SharedPreferences
|
|||
import android.text.InputType
|
||||
import android.util.Log
|
||||
import android.widget.Toast
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.extension.BuildConfig
|
||||
import eu.kanade.tachiyomi.extension.all.komga.dto.AuthorDto
|
||||
import eu.kanade.tachiyomi.extension.all.komga.dto.BookDto
|
||||
import eu.kanade.tachiyomi.extension.all.komga.dto.CollectionDto
|
||||
|
@ -17,7 +17,6 @@ import eu.kanade.tachiyomi.extension.all.komga.dto.SeriesDto
|
|||
import eu.kanade.tachiyomi.network.GET
|
||||
import eu.kanade.tachiyomi.network.asObservableSuccess
|
||||
import eu.kanade.tachiyomi.source.ConfigurableSource
|
||||
import eu.kanade.tachiyomi.source.UnmeteredSource
|
||||
import eu.kanade.tachiyomi.source.model.Filter
|
||||
import eu.kanade.tachiyomi.source.model.FilterList
|
||||
import eu.kanade.tachiyomi.source.model.MangasPage
|
||||
|
@ -45,7 +44,7 @@ import java.text.SimpleDateFormat
|
|||
import java.util.Date
|
||||
import java.util.Locale
|
||||
|
||||
open class Komga(suffix: String = "") : ConfigurableSource, UnmeteredSource, HttpSource() {
|
||||
open class Komga(suffix: String = "") : ConfigurableSource, HttpSource() {
|
||||
override fun popularMangaRequest(page: Int): Request =
|
||||
GET("$baseUrl/api/v1/series?page=${page - 1}&deleted=false", headers)
|
||||
|
||||
|
@ -397,7 +396,7 @@ open class Komga(suffix: String = "") : ConfigurableSource, UnmeteredSource, Htt
|
|||
|
||||
override fun headersBuilder(): Headers.Builder =
|
||||
Headers.Builder()
|
||||
.add("User-Agent", "TachiyomiKomga/${AppInfo.getVersionName()}")
|
||||
.add("User-Agent", "TachiyomiKomga/${BuildConfig.VERSION_NAME}")
|
||||
|
||||
private val preferences: SharedPreferences by lazy {
|
||||
Injekt.get<Application>().getSharedPreferences("source_$id", 0x0000)
|
||||
|
|
|
@ -4,7 +4,7 @@ import android.app.Application
|
|||
import android.content.SharedPreferences
|
||||
import android.text.InputType
|
||||
import android.widget.Toast
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.BuildConfig
|
||||
import eu.kanade.tachiyomi.network.GET
|
||||
import eu.kanade.tachiyomi.network.POST
|
||||
import eu.kanade.tachiyomi.network.asObservableSuccess
|
||||
|
@ -212,7 +212,7 @@ class Mango : ConfigurableSource, HttpSource() {
|
|||
|
||||
override fun headersBuilder(): Headers.Builder =
|
||||
Headers.Builder()
|
||||
.add("User-Agent", "Tachiyomi Mango v${AppInfo.getVersionName()}")
|
||||
.add("User-Agent", "Tachiyomi Mango v${BuildConfig.VERSION_NAME}")
|
||||
|
||||
private val preferences: SharedPreferences by lazy {
|
||||
Injekt.get<Application>().getSharedPreferences("source_$id", 0x0000)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
package eu.kanade.tachiyomi.extension.ca.fansubscat
|
||||
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.BuildConfig
|
||||
import eu.kanade.tachiyomi.network.GET
|
||||
import eu.kanade.tachiyomi.network.asObservableSuccess
|
||||
import eu.kanade.tachiyomi.source.model.FilterList
|
||||
|
@ -37,7 +37,7 @@ class FansubsCat : HttpSource() {
|
|||
override val supportsLatest = true
|
||||
|
||||
override fun headersBuilder(): Headers.Builder = Headers.Builder()
|
||||
.add("User-Agent", "Tachiyomi/FansubsCat/${AppInfo.getVersionName()}")
|
||||
.add("User-Agent", "Tachiyomi/FansubsCat/${BuildConfig.VERSION_NAME}")
|
||||
|
||||
override val client: OkHttpClient = network.client
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
package eu.kanade.tachiyomi.extension.en.vgperson
|
||||
|
||||
import android.os.Build.VERSION
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.BuildConfig
|
||||
import eu.kanade.tachiyomi.network.GET
|
||||
import eu.kanade.tachiyomi.network.asObservableSuccess
|
||||
import eu.kanade.tachiyomi.source.model.FilterList
|
||||
|
@ -29,7 +29,7 @@ class Vgperson : ParsedHttpSource() {
|
|||
|
||||
private val userAgent = "Mozilla/5.0 " +
|
||||
"(Android ${VERSION.RELEASE}; Mobile) " +
|
||||
"Tachiyomi/${AppInfo.getVersionName()}"
|
||||
"Tachiyomi/${BuildConfig.VERSION_NAME}"
|
||||
|
||||
override fun headersBuilder() = Headers.Builder().apply {
|
||||
add("User-Agent", userAgent)
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
package eu.kanade.tachiyomi.extension.en.warforrayuba
|
||||
|
||||
import android.os.Build
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.BuildConfig
|
||||
import eu.kanade.tachiyomi.extension.en.warforrayuba.dto.PageDto
|
||||
import eu.kanade.tachiyomi.extension.en.warforrayuba.dto.RoundDto
|
||||
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
|
||||
|
@ -47,7 +47,7 @@ class WarForRayuba : HttpSource() {
|
|||
"User-Agent",
|
||||
"(Android ${Build.VERSION.RELEASE}; " +
|
||||
"${Build.MANUFACTURER} ${Build.MODEL}) " +
|
||||
"Tachiyomi/${AppInfo.getVersionName()} " +
|
||||
"Tachiyomi/${BuildConfig.VERSION_NAME} " +
|
||||
Build.ID
|
||||
)
|
||||
}.build()
|
||||
|
|
|
@ -3,7 +3,7 @@ package eu.kanade.tachiyomi.extension.ko.jmana
|
|||
import android.app.Application
|
||||
import android.content.SharedPreferences
|
||||
import android.widget.Toast
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.BuildConfig
|
||||
import eu.kanade.tachiyomi.network.GET
|
||||
import eu.kanade.tachiyomi.source.ConfigurableSource
|
||||
import eu.kanade.tachiyomi.source.model.FilterList
|
||||
|
@ -201,7 +201,7 @@ class JMana : ConfigurableSource, ParsedHttpSource() {
|
|||
const val DETAIL_DESCRIPTION = "설명 : "
|
||||
const val DEFAULT_BASEURL = "https://jmana1.net"
|
||||
private const val BASE_URL_PREF_TITLE = "Override BaseUrl"
|
||||
private val BASE_URL_PREF = "overrideBaseUrl_v${AppInfo.getVersionName()}"
|
||||
private val BASE_URL_PREF = "overrideBaseUrl_v${BuildConfig.VERSION_NAME}"
|
||||
private const val BASE_URL_PREF_SUMMARY = "For temporary uses. Update extension will erase this setting."
|
||||
private const val RESTART_TACHIYOMI = "Restart Tachiyomi to apply new setting."
|
||||
}
|
||||
|
|
|
@ -4,8 +4,8 @@ import android.annotation.SuppressLint
|
|||
import android.app.Application
|
||||
import android.content.SharedPreferences
|
||||
import android.widget.Toast
|
||||
import eu.kanade.tachiyomi.BuildConfig
|
||||
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.network.GET
|
||||
import eu.kanade.tachiyomi.network.asObservableSuccess
|
||||
import eu.kanade.tachiyomi.source.ConfigurableSource
|
||||
|
@ -375,7 +375,7 @@ open class NewToki(override val name: String, private val defaultBaseUrl: String
|
|||
private const val RESTART_TACHIYOMI = "Restart Tachiyomi to apply new setting."
|
||||
|
||||
private const val BASE_URL_PREF_TITLE = "Override BaseUrl"
|
||||
private val BASE_URL_PREF = "overrideBaseUrl_v${AppInfo.getVersionName()}"
|
||||
private val BASE_URL_PREF = "overrideBaseUrl_v${BuildConfig.VERSION_NAME}"
|
||||
private const val BASE_URL_PREF_SUMMARY = "For temporary uses. Update extension will erase this setting."
|
||||
|
||||
// Setting: Experimental Latest Fetcher
|
||||
|
|
|
@ -3,7 +3,7 @@ package eu.kanade.tachiyomi.extension.ko.toonkor
|
|||
import android.app.Application
|
||||
import android.content.SharedPreferences
|
||||
import android.util.Base64
|
||||
import eu.kanade.tachiyomi.AppInfo
|
||||
import eu.kanade.tachiyomi.BuildConfig
|
||||
import eu.kanade.tachiyomi.network.GET
|
||||
import eu.kanade.tachiyomi.source.ConfigurableSource
|
||||
import eu.kanade.tachiyomi.source.model.Filter
|
||||
|
@ -28,7 +28,7 @@ class Toonkor : ConfigurableSource, ParsedHttpSource() {
|
|||
|
||||
private val defaultBaseUrl = "https://tkor.dog"
|
||||
|
||||
private val BASE_URL_PREF = "overrideBaseUrl_v${AppInfo.getVersionName()}"
|
||||
private val BASE_URL_PREF = "overrideBaseUrl_v${BuildConfig.VERSION_NAME}"
|
||||
|
||||
override val baseUrl by lazy { getPrefBaseUrl() }
|
||||
|
||||
|
|
|
@ -104,7 +104,7 @@ class MangaClub : ParsedHttpSource() {
|
|||
}
|
||||
description = "Читайте описание через WebView"
|
||||
genre = document.select("div.info a[href*=tags]").joinToString(", ") {
|
||||
it.text().replaceFirstChar { it.toUpperCase() }.trim()
|
||||
it.text().replaceFirst(it.text().first(), it.text().first().toUpperCase()).trim()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
|
||||
apply plugin: 'com.android.application'
|
||||
apply plugin: 'kotlin-android'
|
||||
|
||||
|
|
|
@ -145,7 +145,7 @@ class WuqiManga : ParsedHttpSource() {
|
|||
val html = document.html()
|
||||
val packed = Regex("eval(.*?)\\n").find(html)?.groups?.get(1)?.value
|
||||
val result = Duktape.create().use {
|
||||
it.evaluate(packed!!) as String
|
||||
it.evaluate(packed) as String
|
||||
}
|
||||
val re2 = Regex("""\{.*\}""")
|
||||
val imgJsonStr = re2.find(result)?.groups?.get(0)?.value
|
||||
|
|
Loading…
Reference in New Issue