Quote:
Originally Posted by geek1011
Your first idea would add complexity, but I could do something like your second. Do you mean that I should ship the original binaries with kobopatch so users do not need to download them?
|
No.
User copy&paste all patches in the new format in the same archive (i.e. fwpatch.yaml) along with already existing patch. Of course, each patch must have a variable indicating the archive to patch (nickel, libnickel, etc)
Something like:
When someone use kobopath, the program first read the file fwpatch.yaml and write a temporary file for each archive to patch (nickel.yaml, libnickel.yaml, etc). Then read each new file and execute the patch like it do now.
Finally, all temporary files are deleted.
The idea behind it is that, when a new patch come to forum, the user should not worry where to put it. All must be copy in the same file without error possibility.
---------------------------
About multipart patch for two archive:
I suppose that the variable "PatchGroup" work checking if only one in the same group are enable. So if all patch are in the same file you can add a new variable "MultiPatch" checking that all patch in the same group are enable at first read.
Something like that:
Spoiler:
# Multi-version patch: 4.7.10413 - 4.8.10956+
Force user line spacing in ePubs (part 1 of 2):
- Enabled: yes
- PatchFile: libnickel.so.1.0.0
- MultiPatch: Line spacing in ePubs
- Description: |
This is part 1 of 2. Also enable part 2 in librmsdk.so.1.0.0.patch
This patch prevents any line-height style set in the book's stylesheet from
being recognised. It will spoil the formatting of some books, but will
ensure that the line spacing set with the adjustment slider takes effect.
- FindBaseAddressString: "\0\0\x20line-height: %1"
- ReplaceString: {Offset: 0x0003, Find: "l", Replace: "_"}
# Multi-version patch: 3.3.0 - 4.8.10956+
Force user line spacing in ePubs (Part 2 of 2):
- Enabled: yes
- PatchFile: librmsdk.so.1.0.0
- MultiPatch: Line spacing in ePubs
# This is part 2 of 2. Also enable part 1 in libnickel.so.1.0.0.patch
#
# This patch prevents any line-height style set in the book's stylesheet from
# being recognised. It will spoil the formatting of some books, but will ensure
# that the line spacing set with the adjustment slider takes effect. (Unless
# the publisher has used the font shorthand style; see option below.)
- FindBaseAddressString: "\0line-height\0"
- ReplaceString: {Offset: 0x0001, Find: "l", Replace: "_"}
#
# Uncomment the following two lines to also prevent the font shorthand style
# from being recognised. The font shorthand style is not very common in ePubs,
# but where used it can also prevent the line spacing from being adjusted.
# Beware that this option will likely have much bigger side-effects on the
# book's formatting, because the font shorthand style is used to set the
# font-size, font family, and other styles in addition to line-height.
#
# - FindBaseAddressString: "\0font\0"
# - ReplaceString: {Offset: 0x0001, Find: "f", Replace: "_"}