diff --git a/.github/workflows/build_push.yml b/.github/workflows/build_push.yml index 82d1521b..10908a1b 100644 --- a/.github/workflows/build_push.yml +++ b/.github/workflows/build_push.yml @@ -63,7 +63,7 @@ jobs: - id: generate-matrices name: Create output matrices run: | - python ./.github/scripts/generate-build-matrices.py ${{ steps.last_successful_ci_commit.outputs.base }} Release + echo "matrix={\"chunk\":[{\"number\":1,\"modules\":[\"src:all:kavita:assembleRelease\"]}]}" >> $GITHUB_OUTPUT build: name: Build extensions (${{ matrix.chunk.number }}) @@ -89,7 +89,10 @@ jobs: - name: Prepare signing key run: | - echo ${{ secrets.SIGNING_KEY }} | base64 -d > signingkey.jks + echo "${{ secrets.SIGNING_KEY }}" | base64 -di > signingkey.jks + # Verify key is properly created + ls -la signingkey.jks + keytool -list -v -keystore signingkey.jks -storepass "${{ secrets.KEY_STORE_PASSWORD }}" -alias "${{ secrets.ALIAS }}" || exit 1 - name: Build extensions (${{ matrix.chunk.number }}) env: @@ -146,7 +149,7 @@ jobs: uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 with: repository: Kareadita/tach-extension - token: ${{ secrets.BOT_PAT }} + token: ${{ secrets.GITHUB_TOKEN }} ref: repo path: repo diff --git a/README.md b/README.md index cde31d7a..2e17e2f8 100644 --- a/README.md +++ b/README.md @@ -1,23 +1,32 @@ -| Build | Up to date | Install to app | -| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| [](https://github.com/Kareadita/tach-extensions/actions/workflows/build_push.yml) | [](https://github.com/Kareadita/tachiyomi-extensions/actions/workflows/auto_cherry_pick.yml) | [](https://intradeus.github.io/http-protocol-redirector/?r=tachiyomi://add-repo?url=https://raw.githubusercontent.com/Kareadita/tach-extensions/repo/index.min.json) | +
# Kavita Extension -This repository contains the Kavita extension which is compatible with [Komikku](https://github.com/komikku-app/komikku) and Mihon / Tachiyomi or other forks. +This repository contains the Kavita extension, compatible with [Komikku](https://github.com/komikku-app/komikku), [Mihon](https://github.com/mihonapp/mihon), Tachiyomi, and other forks. -## Recommend App +## Recommended Apps -### [Mihon](https://github.com/mihonapp/mihon) +### - [Mihon](https://github.com/mihonapp/mihon) -### [Komikku](https://github.com/komikku-app/komikku) +### - [Komikku](https://github.com/komikku-app/komikku) ## How to add the repo -[](https://intradeus.github.io/http-protocol-redirector/?r=tachiyomi://add-repo?url=https://raw.githubusercontent.com/Kareadita/tach-extensions/repo/index.min.json) -Otherwise, copy & paste the following URL: +[](https://intradeus.github.io/http-protocol-redirector/?r=tachiyomi://add-repo?url=https://raw.githubusercontent.com/Kareadita/tach-extensions/repo/index.min.json) -```html +Or copy & paste this URL into your app: + +``` https://raw.githubusercontent.com/Kareadita/tach-extensions/repo/index.min.json ``` @@ -60,7 +69,6 @@ limitations under the License. This project does not have any affiliation with the content providers available. -This project is not affiliated with Komikku/Mihon/Tachiyomi. Don't ask for help about these extensions at the -official support means of Komikku/Mihon/Tachiyomi. All credits to the codebase goes to the original contributors. +This project is not affiliated with Komikku/Mihon/Tachiyomi. Don't ask for help about these extensions at the official support means of Komikku/Mihon/Tachiyomi. All credits to the codebase goes to the original contributors. The developer of this application does not have any affiliation with the content providers available. diff --git a/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/Kavita.kt b/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/Kavita.kt index 94f548d0..4258e847 100644 --- a/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/Kavita.kt +++ b/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/Kavita.kt @@ -350,17 +350,22 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou } name = buildString { append("${item.order + 1}. ") - if (item.chapterId != null && item.chapterId > 0) { - if (item.chapterTitleName.isNullOrBlank()) { - item.chapterNumber - ?.takeIf { it.isNotBlank() && it != "-100000" } - ?.let { append(" Chapter $it") } + when { + !item.chapterTitleName.isNullOrBlank() && !item.chapterTitleName.matches(Regex("^\\d+\$")) -> { + append(item.chapterTitleName) + } + !item.volumeNumber.isNullOrBlank() && item.volumeNumber != "-100000" -> { + append("Volume ${item.volumeNumber.padStart(2, '0')}") + } + !item.chapterNumber.isNullOrBlank() && item.chapterNumber != "-100000" -> { + val libraryType = getLibraryType(item.seriesId) + when (libraryType) { + LibraryTypeEnum.Comic, LibraryTypeEnum.ComicVine -> + append("Issue #${item.chapterNumber.padStart(3, '0')}") + else -> + append("Chapter ${item.chapterNumber.padStart(2, '0')}") + } } - item.chapterTitleName - ?.takeIf { it.isNotBlank() } - ?.let { append(it) } - } else if (!item.volumeNumber.isNullOrBlank()) { - append(" (Vol.${item.volumeNumber})") } } date_upload = if (preferences.RdDate && !item.releaseDate.isNullOrBlank()) { @@ -369,7 +374,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou 0L // Explicitly unset the date } chapter_number = item.order.toFloat() - scanlator = item.seriesName + " #" + (item.chapterNumber?.padStart(3, '0') ?: "") // For Comics #000 + scanlator = item.seriesName } }.sortedBy { it.chapter_number } }