Repository navigation
Read Krita's .kra~ backup files (#1077) - #1101
Merged
Merged
Conversation
Krita keeps the previous save as "name.kra~", the same KRA file under another name. The KRA entry now lists "kra~" as one of its extensions, like the png_large / jpg_large aliases, so the backup is detected as KRA, opens the images donut and converts to "name.png". - Schema 65: the images donut learns "kra~"; custom claims stay put. - The donut editor accepts extensions Filee knows as they are, so the suggested ".kra~" can be added (it refused the "~" before). - Watch folders skip names ending in "~": Krita writes the backup next to the drawing on every save, and converting it too would put the previous picture under the same output name. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
#1094 (DBML) took schema 65 first. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
rohitLovesKrishna
pushed a commit
to rohitLovesKrishna/Filee
that referenced
this pull request
Nov 4, 2026
The win-arm64 job hung at "Build Explorer menu extension" twice on 2026-11-04 (KnifeLemon#1090, KnifeLemon#1101) until the two-hour limit, while the same step takes about two minutes. zig cc now gets eight minutes per try, three tries, each retry with a cache of its own; the step itself stops after 30 minutes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
Krita keeps the previous save as
name.kra~: the same KRA file under another name. Filee now reads it as KRA, so it converts like.kra(PNG, JPG, WebP, PDF, …) and the output is namedname.png.kra~is one more extension of the KRA entry inFormatRegistry, next tokra.Path.GetExtension("name.kra~")is.kra~, so detection, the images donut and the output name (NameWithoutExtension→name) all work without new code. This is the same thing thepng_large/jpg_largealiases do.kra~; a user's own donut that already claims it keeps it. (Schema 65 may be renumbered if another change takes it first: the.dbmland FLIC PRs add one each, and feat(tools): Add background tool #1081 just took 64.)~was refused, so the.kra~the autocomplete offers couldn't be added back after removing it. Unknown text still has to be letters, digits and- _ + ..~. Krita writes the backup next to the drawing on every save; converting it too would put the previous picture under the samename.png. Before this change.kra~was simply unknown, so watch folders behave as they did.docs/ENGINES.md: one line on the backup in the KRA paragraph.Why not a general "trailing
~" fallbackA fallback in
ExtensionOf/Detectthat strips any trailing~would also makenotes.txt~,report.docx~,config.ini~(Emacs / gedit backups) convertible, change whatExtensionOfreturns for every caller (donut matching, output names, watch folders, the format request), and would need its own rule for donut extensions. Only Krita's backup was asked for, and it is a byte-for-byte KRA, so one more extension is the narrowest correct change. If more~backups come up, the fallback can still be added then.How it was tested
FormatRegistryTests:sketch.kra~is detected askra.ImageExtensionAliasTests:.kra~(any case) is KRA, namedsketch, and opens the images donut together with.kra;notes.txt~/sketch.kr~are not detected; schema 64 → 65 learnskra~once and leaves a custom claim alone.OutputPathResolverTests:sketch.kra~→sketch.png.FolderWatcherTests: a watch folder ignoressketch.kra~.ExtensionInputTests:*.KRA~→kra~;txt~is still refused.KritaTests(engine): a generatedsketch.kra~converts tosketch.pngfrom its merged picture.dotnet build Filee.slnx; all ofFilee.Core.Tests(977 passed, 3 skipped, incl.FormatFieldsTests);KritaTests(5);ExtensionInputTests+LocalizationTests(250);dotnet format Filee.slnx --verify-no-changes.Filee.App.Testsran once before the rebase onto feat(tools): Add background tool #1081: 1826 passed, 6 skipped, 2 failed.MergeOrderTestspasses on its own (a timing failure under load);RenderTests.Engines_page_shows_versions_descriptions_and_download_speedfails on this PC because a system Tesseract (C:\Program Files\Tesseract-OCR) reports no version; neither touches this change.Closes #1077
🤖 Generated with Claude Code