How Does backup-directory-alist Interact with version-control and backup-by-copying When Restoring Centralized Backups?
0 reputation · 20 Mar 2024, 10:51 UTC
When backup-directory-alist redirects backups to a central location, Emacs transforms original filenames to avoid collisions, while version-control and backup-by-copying further influence naming and filesystem metadata. The documentation describes each variable independently, but their combined effect on restoration is not specified: a user must locate the correct transformed backup, decide whether to copy or rename it back, and account for permission or timestamp changes introduced by backup-by-copying. No built-in command automates this lookup or verifies that the restored file matches the intended version.
Given that backups in the central directory lack checksums and may be pruned by kept-new-versions or kept-old-versions, a reliable restoration workflow requires manual correlation of transformed names with original paths and an external integrity check.
- Which transformed naming scheme does Emacs apply when
backup-directory-alistandversion-controlare both active? - Does
backup-by-copyingpreserve the original file's permissions and timestamps on the restored copy, or does it inherit the backup file's metadata? - What practical steps can identify the correct backup version in the central directory without inspecting every candidate?