Repository navigation
feat(presets): add Copy to folder tools on the back face - #814
Conversation
|
Thanks, @1644ye! Saving a browser drop's original bytes without converting overlaps with things Filee already has:
Adding a separate Download action with its own location settings needs a design decision first. Please open an issue with:
New features start with an issue so we agree on the shape before the code. I'll keep this draft open until then. |
|
Thanks for the scope feedback. I opened #821 with the concrete workflow, existing behavior, and the smaller integration options for discussion. This PR will remain draft while we agree on the requirement and scope. |
|
Reworked to the agreed scope in This is now a user-created Copy to folder preset on the back face, including groups and every file type. It copies browser originals, local files and folders without moving sources, reuses the existing fixed-folder / Ask every time UI, numbers clashes, fails missing destinations without creating them, and lets watched destinations process complete copies. The separate Download settings and default Download slice are gone.
Editor and grouped-folder screenshots are in the updated PR description and review evidence. Marking ready for your CI approval. |
KnifeLemon
left a comment
There was a problem hiding this comment.
Thanks @1644ye, this is exactly the scope we agreed in #821. The PR is clean and well tested.
What I checked:
FolderCopy.CopyAsync: the copy goes to.filee-copy-….tmpinside the destination first, then moves into place withoverwrite: false.- Watchers never see half-written files (
IsWorkPath). - A clash just tries the next number.
- The
finallyonly removes this run's stage, never the source or a published result.
- Watchers never see half-written files (
- Folders:
- copying a folder into itself or a subfolder is refused;
- linked directories are refused instead of followed;
- empty folders are kept.
- Same folder returns
null→ Skipped, and a missing destination throws before anything is created. IsCropToolnow checksKind == PresetKind.Tool, so a copy preset can't fall into the crop path. Good catch.- Tests cover the cases we listed, including the real browser drop → byte comparison. CI is green on all platforms.
Two small things, neither blocking. They'd fit a follow-up if you like:
- Error text: a missing destination shows
error.conversion_failedwith the English exception message as detail. A key of its own (for exampleerror.copy_destination_missing) would read better in the other 18 languages. - Downgrades: a settings file with a
CopyToFolderpreset makes an older Filee fail to read that preset's kind. That's acceptable for a new feature, but worth a line in the CHANGELOG entry when it ships.
Approving and merging.
Add a user-created Copy to folder preset: browser originals, local files and batches of files/folders are copied byte for byte. Local originals are never moved or replaced. No slices are added to the default donuts.
The preset editor reuses the existing fixed output folder and Ask every time choices. A single file can be renamed in the existing save dialog; batches/folders use the folder picker. Cancelling creates no job. The former Download settings and built-in Download slice have been removed from this PR.
Closes #821. Reuses #521 and follows #806.
Validation on Windows / .NET 10, based on upstream
7fc129f:dotnet format Filee.slnx --no-restore --verify-no-changes: passed.The initial full run exposed an existing test cleanup bug: the random tray-click test retained simulated click flags and reopened the main window while cleaning up, causing five later tests to fail. A minimal combination reproduced it. Commit
099adb5clears those flags only in the test's cleanup and asserts the window is gone; it does not change production window behavior. The complete App project was then rerun successfully with normal collection parallelism.App/engine tests used isolated
FILEE_DATA_DIR; Setup was rerun without that override because it asserts real default paths. Optional-engine/OS-specific/Explorer-package/symlink tests and the intentionally disabled upstream media-generation test remain skipped; none are counted as passed. Directory symlinks/reparse points fail explicitly rather than being followed during folder copying.Screenshots rendered from the actual Avalonia views in the UI tests:
Chinese screenshots and validation details.