feat(mobi): allow to pass custom arguments to kindlegen#730
Conversation
|
Ah, I just see I simply revisited my old PR #628... I completely forgot about that 😅 The use case here is still valid. Moving to Kindling is the only option for the present and future, and it has several interesting arguments that one would want to use without using a PyGlossary fork. |
|
Would using an environment variable solve that problem? Because I think anyone who knows enough to set the extra args via options in UI, can just run the kindlegen command afterwards. |
|
Kindlegen deprecation is a joke: it is so since 2014, and then Amazon did not care sharing a decent tool for Linux developers. So it is still in use 12 years later. That's not a problem, just the reality of the situation. The good news is this new tool in the game: Kindling. But it is too young and doesn't work yet as a replacement for kindlegen. Whatever you decide to do with MobiPocket support in PyGlossary, we will need a way to pass additional arguments for Kindling: there are way more options possible and covering all cases won't be possible. Even good defaults could be potentially debated. About your proposal, I will be happy with whatever option you think is better as soon as we can provide more arguments to kindlegen/kindling :) That's also true that I can use PyGlossary only partially and call kindlegen/kindling in a second manual pass; it's just way more convenient to use PyGlossary to do all the work since it allows us to easily centralize the code (for instance in reader.dict I've one method to call PyGlossary with different options given the desired output format. But that's only my use case and shouldn't drive the general path for this project). Do you plan to deprecate, and remove, MobiPocket support from PyGlossary at some point? I'm OK with closing the PR and deal with kindlegen/kindling on my end :) |
No. Let's use |
|
Closing this one since Kindling is now using envars. No need to complexify here. |
This patch keeps the current behavior and add the capability to pass custom arguments to kindlegen.
Benefits:
-verbosein non-debug runs (I wanted that without having to be flooded by DEBUG logs).Changes tested locally with success.