Initial commit

This commit is contained in:
FourTOne5
2024-01-09 04:12:39 +06:00
commit 600c345dfe
8593 changed files with 150590 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
<application>
<activity
android:name="eu.kanade.tachiyomi.multisrc.heancms.HeanCmsUrlActivity"
android:excludeFromRecents="true"
android:exported="true"
android:theme="@android:style/Theme.NoDisplay">
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data
android:host="${SOURCEHOST}"
android:pathPattern="/.*/..*"
android:scheme="${SOURCESCHEME}" />
</intent-filter>
</activity>
</application>
</manifest>

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 29 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 104 KiB

View File

@@ -0,0 +1,48 @@
package eu.kanade.tachiyomi.extension.en.omegascans
import eu.kanade.tachiyomi.multisrc.heancms.Genre
import eu.kanade.tachiyomi.multisrc.heancms.HeanCms
import eu.kanade.tachiyomi.network.interceptor.rateLimitHost
import okhttp3.HttpUrl.Companion.toHttpUrl
class OmegaScans : HeanCms("Omega Scans", "https://omegascans.org", "en") {
override val client = super.client.newBuilder()
.rateLimitHost(apiUrl.toHttpUrl(), 1)
.build()
override val useNewQueryEndpoint = true
// Site changed from MangaThemesia to HeanCms.
override val versionId = 2
override val coverPath = ""
override fun getGenreList() = listOf(
Genre("Romance", 1),
Genre("Drama", 2),
Genre("Fantasy", 3),
Genre("Hardcore", 4),
Genre("SM", 5),
Genre("Harem", 8),
Genre("Hypnosis", 9),
Genre("Novel Adaptation", 10),
Genre("Netori", 11),
Genre("Netorare", 12),
Genre("Isekai", 13),
Genre("Yuri", 14),
Genre("MILF", 16),
Genre("Office", 17),
Genre("Short Story", 18),
Genre("Comedy", 19),
Genre("Campus", 20),
Genre("Crime", 21),
Genre("Revenge", 22),
Genre("Supernatural", 23),
Genre("Action", 24),
Genre("Military", 25),
Genre("Ability", 26),
Genre("Cohabitation", 27),
Genre("Training", 28),
)
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 111 KiB

View File

@@ -0,0 +1,17 @@
package eu.kanade.tachiyomi.extension.fr.perfscan
import eu.kanade.tachiyomi.multisrc.heancms.HeanCms
import eu.kanade.tachiyomi.network.interceptor.rateLimitHost
import okhttp3.HttpUrl.Companion.toHttpUrl
import okhttp3.OkHttpClient
class PerfScan : HeanCms("Perf Scan", "https://perf-scan.fr", "fr") {
override val client: OkHttpClient = super.client.newBuilder()
.rateLimitHost(apiUrl.toHttpUrl(), 1, 2)
.build()
override val coverPath: String = ""
override val useNewQueryEndpoint = true
override val slugStrategy = SlugStrategy.ID
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 25 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 102 KiB

View File

@@ -0,0 +1,35 @@
package eu.kanade.tachiyomi.extension.en.templescan
import eu.kanade.tachiyomi.multisrc.heancms.Genre
import eu.kanade.tachiyomi.multisrc.heancms.HeanCms
import eu.kanade.tachiyomi.network.interceptor.rateLimit
class TempleScan : HeanCms("Temple Scan", "https://templescan.net", "en") {
override val versionId = 3
override val client = super.client.newBuilder()
.rateLimit(1)
.build()
override val useNewQueryEndpoint = true
override val coverPath = ""
override val mangaSubDirectory = "comic"
override fun getGenreList() = listOf(
Genre("Drama", 1),
Genre("Josei", 2),
Genre("Romance", 3),
Genre("Girls Love", 4),
Genre("Reincarnation", 5),
Genre("Fantasia", 6),
Genre("Ecchi", 7),
Genre("Adventure", 8),
Genre("Boys Love", 9),
Genre("School Life", 10),
Genre("Action", 11),
Genre("Military", 13),
Genre("Comedy", 14),
Genre("Apocalypse", 15),
)
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 39 KiB

View File

@@ -0,0 +1,165 @@
package eu.kanade.tachiyomi.extension.es.yugenmangas
import android.app.Application
import android.content.SharedPreferences
import eu.kanade.tachiyomi.multisrc.heancms.Genre
import eu.kanade.tachiyomi.multisrc.heancms.HeanCms
import eu.kanade.tachiyomi.network.interceptor.rateLimitHost
import okhttp3.HttpUrl.Companion.toHttpUrl
import okhttp3.Interceptor
import okhttp3.ProtocolException
import okhttp3.Response
import uy.kohesive.injekt.Injekt
import uy.kohesive.injekt.api.get
import java.io.IOException
import java.text.SimpleDateFormat
import java.util.TimeZone
import java.util.concurrent.TimeUnit
class YugenMangas :
HeanCms(
"YugenMangas",
"https://yugenmangas.net",
"es",
"https://api.yugenmangas.net",
) {
// Site changed from Madara to HeanCms.
override val versionId = 2
override val baseUrl by lazy { getPrefBaseUrl() }
private val preferences by lazy {
Injekt.get<Application>().getSharedPreferences("source_$id", 0x0000)
}
private var lastDomain = ""
private fun domainChangeIntercept(chain: Interceptor.Chain): Response {
val request = chain.request()
if (!request.url.host.startsWith("yugenmangas")) {
return chain.proceed(request)
}
if (lastDomain.isNotEmpty()) {
val newUrl = request.url.newBuilder()
.host(preferences.baseUrlHost)
.build()
return chain.proceed(
request.newBuilder()
.url(newUrl)
.build(),
)
}
val response = try {
chain.proceed(request)
} catch (e: ProtocolException) {
if (e.message?.contains("Too many follow-up requests") == true) {
throw IOException("No se pudo obtener la nueva URL del sitio")
} else {
throw e
}
}
if (request.url.host == response.request.url.host) return response
response.close()
preferences.baseUrlHost = response.request.url.host
lastDomain = request.url.host
val newUrl = request.url.newBuilder()
.host(response.request.url.host)
.build()
return chain.proceed(
request.newBuilder()
.url(newUrl)
.build(),
)
}
override val slugStrategy = SlugStrategy.ID
override val useNewQueryEndpoint = true
override val client = super.client.newBuilder()
.connectTimeout(60, TimeUnit.SECONDS)
.readTimeout(90, TimeUnit.SECONDS)
.rateLimitHost(apiUrl.toHttpUrl(), 2, 3)
.addInterceptor(::domainChangeIntercept)
.build()
override val coverPath: String = ""
override val dateFormat: SimpleDateFormat = super.dateFormat.apply {
timeZone = TimeZone.getTimeZone("UTC")
}
override fun getGenreList(): List<Genre> = listOf(
Genre("+18", 1),
Genre("Acción", 36),
Genre("Adulto", 38),
Genre("Apocalíptico", 3),
Genre("Artes marciales (1)", 16),
Genre("Artes marciales (2)", 37),
Genre("Aventura", 2),
Genre("Boys Love", 4),
Genre("Ciencia ficción", 39),
Genre("Comedia", 5),
Genre("Demonios", 6),
Genre("Deporte", 26),
Genre("Drama", 7),
Genre("Ecchi", 8),
Genre("Familia", 9),
Genre("Fantasía", 10),
Genre("Girls Love", 11),
Genre("Gore", 12),
Genre("Harem", 13),
Genre("Harem inverso", 14),
Genre("Histórico", 48),
Genre("Horror", 41),
Genre("Isekai", 40),
Genre("Josei", 15),
Genre("Maduro", 42),
Genre("Magia", 17),
Genre("MangoScan", 35),
Genre("Mecha", 18),
Genre("Militar", 19),
Genre("Misterio", 20),
Genre("Psicológico", 21),
Genre("Realidad virtual", 46),
Genre("Recuentos de la vida", 25),
Genre("Reencarnación", 22),
Genre("Regresion", 23),
Genre("Romance", 24),
Genre("Seinen", 27),
Genre("Shonen", 28),
Genre("Shoujo", 29),
Genre("Sistema", 45),
Genre("Smut", 30),
Genre("Supernatural", 31),
Genre("Supervivencia", 32),
Genre("Tragedia", 33),
Genre("Transmigración", 34),
Genre("Vida Escolar", 47),
Genre("Yaoi", 43),
Genre("Yuri", 44),
)
companion object {
private const val defaultBaseUrlHost = "yugenmangas.net"
private const val BASE_URL_PREF = "prefOverrideBaseUrl"
}
private var SharedPreferences.baseUrlHost
get() = getString(BASE_URL_PREF, defaultBaseUrlHost) ?: defaultBaseUrlHost
set(newHost) {
edit().putString(BASE_URL_PREF, newHost).commit()
}
private fun getPrefBaseUrl(): String = preferences.baseUrlHost.let { "https://$it" }
}