Repository navigation
Conversation
…eLocation, storytold#1116) A library folder or disk that is now somewhere else (moved or renamed outside LightCraft, a disk back at another drive letter or mount point, /Volumes/tokyo back as /Volumes/TOKYO, a library from another machine's D:\) is pointed at its new place in one undo step: its photos and those of the folders inside it are relinked to the same names there, colour labels follow, and a chosen folder follows on undo and redo. No file is touched; no catalog format change (a Batch of Op::Relink plus folder-record ops, like Rename Folder). FolderMove gains on_disk so the undo entry follows the folder without renaming anything. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
Author
|
Closing in favour of #1122, which does the same thing (same command id, same |
7 tasks done
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.
Part of #1116 (first step). Also the engine half of #1112.
What
folder.updateLocation {path, to}: Lightroom Classic's Update Folder Location, for agents and MCP. A library folder or disk that is now somewhere else can be pointed at its new place as one undo step. That covers a folder moved or renamed outside LightCraft, a USB disk or NAS that came back at another drive letter or mount point,/Volumes/tokyoback as/Volumes/TOKYO, and a library made on another machine (D:\Photos\…).to.folder_records_follow, as Rename / Move Folder already does.folder_key), so either separator works and so does Windows case.toisn't a folder.How
This is
move_folder(Rename / Move Folder) without the disk rename. It's aBatchof the existingOp::Relinks plus the folder-record ops, so there's no new op and no catalog format change. It doesn't touchjournal::VERSION, so it can't collide with #800 / #814 / #974.The one engine change outside the command:
FolderMovegainson_disk. The undo entry still carries the folder, so undo and redo make the chosen folder follow, but withon_disk: falsethey never rename anything on disk.#1116 proposed a root table (
(root, relative path)) first. While writing this, I found the existing relink + folder-record machinery already gives the user-visible result, without a format bump. The root table can still come later, if you want it for #880 (per-device paths) or to keep a whole-disk move small in the log. Each photo is oneRelinkin the step today, the same as Rename Folder.Tests
In
crates/engine/src/tests_folders.rs:tokyo→TOKYO);D:\Photos\…, both separators) pointed at a folder here;Docs
docs/parity-checklist.md: a new row, LRC-LIB-UPDATEFOLDER (🟡: agents only for now); the two LRC-LIB-LIBFOLDERS limits it addresses now point at it; summary regenerated.docs/whats-new.md: a new entry.Next (separate PRs)
Checks
On macOS (Rust 1.99):
-D warnings,cargo test --workspace, parity, layers, assets and wasm pass.chunks-exact-to-as-chunkslint (Issue #989: clippy 1.99, fill_box reads its buffer with as_chunks::<3>() (item 4) #997);on_exitbuild error (Fix macOS build: menu-bar Quit no longer calls eframe's on_exit #994);tests_lock::…spawns_processes, which can't findtrue(Issue #989: the lock test finds true on the PATH #990).