Skip to content
go-libfossil Check-in [6a440bc42f]
Login

Check-in [6a440bc42f]

Overview
Comment:fix(checkout): revert a symlink as fossil's revert does

restoreCommitted writes through vfile.Disk with the row's islink, so a repointed link is made a link to its committed target again instead of having that name written into the file it points to.

Timelines: family | ancestors | descendants | both | main | trunk | feat/submanifest-reader
Files: files | file ages | folders
SHA3-256: 6a440bc42fc7e411a11df3c861501f09c183370da9d7f06ac770c34c3af5d985
User & Date: [email protected] on 2026-10-19 23:02:52.000
Other Links: branch diff | manifest | tags
Context
2026-10-19
23:06
fix(stash): stash, revert and apply symlinks as fossil's stash does

Save reads each changed file through vfile.Disk, so a symlink is stashed as its target's name and recorded with file_islink, and its revert makes it a link to the committed target. Apply writes a stashed symlink as a symlink and deletes a link before writing, so neither writes through one. check-in: 5be36b41a0 user: [email protected] tags: feat/submanifest-reader, main, trunk

23:02
fix(checkout): revert a symlink as fossil's revert does

restoreCommitted writes through vfile.Disk with the row's islink, so a repointed link is made a link to its committed target again instead of having that name written into the file it points to. check-in: 6a440bc42f user: [email protected] tags: feat/submanifest-reader, main, trunk

22:58
fix(undo): save and restore symlinks as fossil's undo does

Move checkout's link-aware diskView into vfile.Disk, so checkout, undo and stash share one RepoFILE view: Stat, Read, Write (which deletes a link before writing, makes a symlink when allow-symlinks is on, creates the directory and sets the executable bit as file_setexe does), SetExe, MTime and Remove. The allow-symlinks setting is read by vfile.OpenDisk.

undo.Save, Undo, Redo, Swap, ReadFile and RestoreFiles now take a Disk: a symlink is read as its target's name and recorded with isLink, and is deleted and made a symlink again on restore, as undo_save and undo_one do, so Undo of an Update no longer writes through a link. check-in: 858c20561f user: [email protected] tags: feat/submanifest-reader, main, trunk

Changes