Den lör 31 juli 2021 kl 05:42 skrev Karl Fogel <kfo...@red-bean.com>:

> On 30 Jul 2021, Daniel Shahaf wrote:
> >How about (hard-|sym)linking the worktree file to the pristine
> >and
> >making it read-only until the user requests it to be made
> >editable?
> >Compare git-annex-unlock(1).
>
> That's an interesting idea.  I'm not sure how portable hard-links
> are, and we can't rely on every file-modifying tool on the user's
> system knowing about this.
>

I'm not sure about what operating systems Subversion really support, but
the Binary packages web page [1] lists only Unix-like OSes and Windows. I
suppose all *nix have hard links. Windows support hard links on NTFS
partitions, but not on ReFS (the "next generation FS" for Windows) and not
on *FAT*. But I have a bad feeling about having a hard link to the pristine
file and managing to avoid some user messing up both the worktree file and
the pristine. I know nothing about git annex, but there it seems that
annex.thin is using the model of hard linking to save disk space but:
"While this can save considerable disk space, any modification made to a
file will cause the old version of the file to be lost from the local
repository. So, enable annex.thin with care."

Kind regards,
Daniel Sahlberg

[1] https://subversion.apache.org/packages.html

Reply via email to