Compare commits

..

8 Commits

Author SHA1 Message Date
Jobobby04 a8e3d105f1 Release v1.8.1 2022-02-01 17:13:02 -05:00
arkon 2f22f56b32 Temporarily revert some things for stable release
(cherry picked from commit b88f8ae9d2)

# Conflicts:
#	app/src/main/java/eu/kanade/tachiyomi/data/download/Downloader.kt
#	app/src/main/java/eu/kanade/tachiyomi/data/library/LibraryUpdateService.kt
2022-02-01 17:12:34 -05:00
Jobobby04 1dd010e733 Minor cleanup 2022-02-01 17:09:41 -05:00
Jobobby04 2eef81c468 Add Mangadex blocked groups and uploaders extension preference support 2022-02-01 17:09:20 -05:00
Jobobby04 ffcb5f6954 Improve collection and string utils 2022-02-01 17:07:57 -05:00
Jobobby04 375455d4a6 Fix renamed manga delete after read 2022-02-01 10:20:15 -05:00
arkon f089991e0b Use default bottom nav height
(cherry picked from commit 836a2649d3)
2022-01-31 18:44:20 -05:00
Jobobby04 26a8b9acc4 Revert "Disable update/download warnings for stable release"
This reverts commit d46879260f.
2022-01-31 18:43:51 -05:00
11 changed files with 56 additions and 20 deletions
+1 -1
View File
@@ -3,7 +3,7 @@
I acknowledge that:
- I have updated:
- To the latest version of the app (stable is v1.8.0)
- To the latest version of the app (stable is v1.8.1)
- All extensions
- I have tried the troubleshooting guide: https://tachiyomi.org/help/guides/troubleshooting-problems/
- If this is an issue with an extension, that I should be opening an issue in https://github.com/tachiyomiorg/tachiyomi-extensions
+2 -2
View File
@@ -53,7 +53,7 @@ body:
label: Tachiyomi version
description: You can find your Tachiyomi version in **More → About**.
placeholder: |
Example: "1.8.0"
Example: "1.8.1"
validations:
required: true
@@ -98,7 +98,7 @@ body:
required: true
- label: I have tried the [troubleshooting guide](https://tachiyomi.org/help/guides/troubleshooting/).
required: true
- label: I have updated the app to version **[1.8.0](https://github.com/jobobby04/tachiyomisy/releases/latest)**.
- label: I have updated the app to version **[1.8.1](https://github.com/jobobby04/tachiyomisy/releases/latest)**.
required: true
- label: I have updated all installed extensions.
required: true
+1 -1
View File
@@ -33,7 +33,7 @@ body:
required: true
- label: If this is an issue with an extension, I should be opening an issue in the [extensions repository](https://github.com/tachiyomiorg/tachiyomi-extensions/issues/new/choose).
required: true
- label: I have updated the app to version **[1.8.0](https://github.com/jobobby04/tachiyomisy/releases/latest)**.
- label: I have updated the app to version **[1.8.1](https://github.com/jobobby04/tachiyomisy/releases/latest)**.
required: true
- label: I will fill out all of the requested information in this form.
required: true
+2 -2
View File
@@ -29,8 +29,8 @@ android {
applicationId = "eu.kanade.tachiyomi.sy"
minSdk = AndroidConfig.minSdk
targetSdk = AndroidConfig.targetSdk
versionCode = 25
versionName = "1.8.0"
versionCode = 26
versionName = "1.8.1"
buildConfigField("String", "COMMIT_COUNT", "\"${getCommitCount()}\"")
buildConfigField("String", "COMMIT_SHA", "\"${getGitSha()}\"")
@@ -155,7 +155,7 @@ class DownloadPendingDeleter(context: Context) {
* Returns a manga entry from a manga model.
*/
private fun Manga.toEntry(): MangaEntry {
return MangaEntry(id!!, url, title, source)
return MangaEntry(id!!, url, originalTitle, source)
}
/**
@@ -95,6 +95,8 @@ class MangaDex(delegate: HttpSource, val context: Context) :
private fun dataSaver() = sourcePreferences.getBoolean(getDataSaverPreferenceKey(mdLang.lang), false)
private fun usePort443Only() = sourcePreferences.getBoolean(getStandardHttpsPreferenceKey(mdLang.lang), false)
private fun blockedGroups() = sourcePreferences.getString(getBlockedGroupsPrefKey(mdLang.lang), "").orEmpty()
private fun blockedUploaders() = sourcePreferences.getString(getBlockedGroupsPrefKey(mdLang.lang), "").orEmpty()
private val mangadexService by lazy {
MangaDexService(client)
@@ -187,11 +189,11 @@ class MangaDex(delegate: HttpSource, val context: Context) :
}
override fun fetchChapterList(manga: SManga): Observable<List<SChapter>> {
return mangaHandler.fetchChapterListObservable(manga)
return mangaHandler.fetchChapterListObservable(manga, blockedGroups(), blockedUploaders())
}
override suspend fun getChapterList(manga: MangaInfo): List<ChapterInfo> {
return mangaHandler.getChapterList(manga)
return mangaHandler.getChapterList(manga, blockedGroups(), blockedUploaders())
}
override fun fetchPageList(chapter: SChapter): Observable<List<Page>> {
@@ -316,5 +318,17 @@ class MangaDex(delegate: HttpSource, val context: Context) :
fun getStandardHttpsPreferenceKey(dexLang: String): String {
return "${standardHttpsPortPref}_$dexLang"
}
private const val blockedGroupsPref = "blockedGroups"
fun getBlockedGroupsPrefKey(dexLang: String): String {
return "${blockedGroupsPref}_$dexLang"
}
private const val blockedUploaderPref = "blockedUploader"
fun getBlockedUploaderPrefKey(dexLang: String): String {
return "${blockedUploaderPref}_$dexLang"
}
}
}
@@ -3,7 +3,6 @@ package exh.eh
import android.content.Context
import eu.kanade.tachiyomi.data.database.DatabaseHelper
import eu.kanade.tachiyomi.data.database.models.Chapter
import eu.kanade.tachiyomi.data.database.models.ChapterImpl
import eu.kanade.tachiyomi.data.database.models.Manga
import eu.kanade.tachiyomi.data.database.models.MangaCategory
import exh.util.executeOnIO
@@ -122,7 +121,7 @@ class EHentaiUpdateHelper(context: Context) {
curChapters
} else {
new = true
curChapters + ChapterImpl().apply {
curChapters + Chapter.create().apply {
manga_id = accepted.manga.id
url = chapter.url
name = chapter.name
@@ -50,14 +50,20 @@ class MangaHandler(
}
}
fun fetchChapterListObservable(manga: SManga): Observable<List<SChapter>> = runAsObservable {
getChapterList(manga.toMangaInfo()).map { it.toSChapter() }
fun fetchChapterListObservable(manga: SManga, blockedGroups: String, blockedUploaders: String): Observable<List<SChapter>> = runAsObservable {
getChapterList(manga.toMangaInfo(), blockedGroups, blockedUploaders).map { it.toSChapter() }
}
suspend fun getChapterList(manga: MangaInfo): List<ChapterInfo> {
suspend fun getChapterList(manga: MangaInfo, blockedGroups: String, blockedUploaders: String): List<ChapterInfo> {
return withIOContext {
val results = mdListCall {
service.viewChapters(MdUtil.getMangaId(manga.key), lang, it)
service.viewChapters(
MdUtil.getMangaId(manga.key),
lang,
it,
blockedGroups,
blockedUploaders
)
}
val groupMap = getGroupMap(results)
@@ -17,6 +17,8 @@ import exh.md.dto.StatisticsDto
import exh.md.utils.MdApi
import exh.md.utils.MdConstants
import exh.md.utils.MdUtil
import exh.util.dropEmpty
import exh.util.trimAll
import okhttp3.CacheControl
import okhttp3.Headers
import okhttp3.HttpUrl.Companion.toHttpUrl
@@ -106,10 +108,14 @@ class MangaDexService(
).await().parseAs(MdUtil.jsonParser)
}
private fun String.splitString() = replace("\n", "").split(',').trimAll().dropEmpty()
suspend fun viewChapters(
id: String,
translatedLanguage: String,
offset: Int,
blockedGroups: String,
blockedUploaders: String
): ChapterListDto {
val url = MdApi.manga.toHttpUrl()
.newBuilder()
@@ -126,6 +132,12 @@ class MangaDexService(
addQueryParameter("contentRating[]", "pornographic")
addQueryParameter("translatedLanguage[]", translatedLanguage)
addQueryParameter("offset", offset.toString())
blockedGroups.splitString().forEach {
addQueryParameter("excludedGroups[]", it)
}
blockedUploaders.splitString().forEach {
addQueryParameter("excludedUploaders[]", it)
}
}
.build()
.toString()
+4 -4
View File
@@ -1,8 +1,8 @@
package exh.util
fun List<String>.trimAll() = map { it.trim() }
fun List<String>.dropBlank() = filter { it.isNotBlank() }
fun List<String>.dropEmpty() = filter { it.isNotEmpty() }
fun Collection<String>.trimAll() = map { it.trim() }
fun Collection<String>.dropBlank() = filter { it.isNotBlank() }
fun Collection<String>.dropEmpty() = filter { it.isNotEmpty() }
private val articleRegex by lazy { "^(an|a|the) ".toRegex(RegexOption.IGNORE_CASE) }
@@ -12,7 +12,7 @@ fun String.removeArticles(): String {
fun String.trimOrNull(): String? {
val trimmed = trim()
return if (trimmed.isBlank()) null else trimmed
return trimmed.ifBlank { null }
}
fun String?.nullIfBlank(): String? = if (isNullOrBlank()) {
+6 -1
View File
@@ -1,12 +1,17 @@
<?xml version="1.0" encoding="utf-8"?>
<changelog bulletedList="true">
<changelogversion versionName="1.8.1" changeDate="Feb 1,2022">
<changelogtext>[b]Based on Tachiyomi stable 0.13.1(from 0.13.0)[/b]</changelogtext>
<changelogtext>[b]New[/b] Use MangaDex blocked groups and uploaders from the extension settings</changelogtext>
<changelogtext>Fixed delete after read for renamed manga</changelogtext>
</changelogversion>
<changelogversion versionName="1.8.0" changeDate="Jan 31,2022">
<changelogtext>[b]Based on Tachiyomi stable 0.13.0(from 0.11.1)[/b]</changelogtext>
<changelogtext>[b]New[/b] When Favorites sync takes longer then 5 seconds for a gallery, display the gallery name</changelogtext>
<changelogtext>[b]Improved[/b] Replace Favorites Sync realm database with the regular database</changelogtext>
<changelogtext>Fix some sources not updating when grouping by source</changelogtext>
<changelogtext>[b]New[/b] Search EHentai uploader on click</changelogtext>
<changelogtext>Fix EH/ExhHentai duplicate rersults in search</changelogtext>
<changelogtext>Fix EH/ExhHentai duplicate results in search</changelogtext>
<changelogtext>[b]New[/b] Add EH/ExhHentai popular as the default browse menu</changelogtext>
<changelogtext>[b]New[/b] Add a toplists filter for E-Hentai</changelogtext>
<changelogtext>[b]Improved[/b] Throw error when ExHentai igneous cookie is mystery</changelogtext>