leotaku / kojirou

Generate perfectly formatted Kindle e-books from MangaDex manga
MIT License
94 stars 9 forks source link

Support for multiple sources. #17

Closed Jamerrone closed 11 months ago

Jamerrone commented 1 year ago

I understand if this is out of focus, but I feel like Kojirou is a bit limited. It's not your fault mind you, and I love, MangaDex, however, there are a lot of missing chapters, especially in English. Some mangas have been completed for years, but people just stopped uploading chapters to MangaDex, for example https://mangadex.org/title/02860cdf-1020-40f1-a23f-2025d80f6290 (should have 25 chapters).

It should be awesome if we could download from multiple manga sources to fill out the gaps.

I understand that I can just look up the missing chapters and read them online, but I enjoy having the complete collection on my Kindle. This is especially an issue if the missing chapters/volumes are in the middle, for example: https://mangadex.org/title/fffbfac3-b7ad-41ee-9581-b4d90ecec941/grand-blue.

leotaku commented 1 year ago

I definitely understand your issue, but unfortunately I am not really interested in maintaining multiple API connectors for various manga sites. The MangaDex API is relatively sane and well-documented and even then, maintaining the client is sometimes a chore.

However, I have some code sitting around locally that allows Kojirou to read images from the file system. That way, you could use any of the already existing Manga downloaders to download your Manga into a Volume>Chapter>Image directory structure and then convert that to a Kindle E-Book. Would this be functionality you are interested in?

Jamerrone commented 1 year ago

Hey, thanks for the fast response. That sounds really helpful, let's say that I download manga x vol 1 chapter 1. Should my folder structure look like this: manga x/1/1/Image directory/image.jpeg? Or is Image directory the chapter folder itself? Either way, I am interested.

leotaku commented 1 year ago

With what I currently have, the structure would be:

Manga Title/
Manga Title/1/          # Volume
Manga Title/1/cover.jpg # Cover
Manga Title/1/1/        # Chapter
Manga Title/1/1/1.jpg   # Page

# When this format is used, the text behind the colon is used for the chapter title.
Manga Title/1/1: Chapter Title/

The other image formats natively supported by the Go stdlib, namely PNG and GIF, can also be used.

As I've said, the code I have for this is not currently in a robust state. When I get to cleaning it up I'll put it in a PR and ping you so you can try it out.

Jamerrone commented 1 year ago

Thank you very much, I will be waiting. But take your time, I can read the missing chapters somewhere else for now, and complete my Kindle collection when you are done.

leotaku commented 11 months ago

I still don't plan to add support for other online sources and I think the issue raised here has been adequately addressed with the "load chapters from disk" feature. As such, I am closing this issue.