On Thu, 30 Nov 2017 13:19:38 +0100 Jan Nijtmans <jan.nijtm...@gmail.com> wrote:
> This patch has no relation to fossil's symlink support, it's just part > of the code to find a suitable temporary directory to write some > intermediate file. It's unfortunate it's that complicated, but useful > because sometimes the working directory or the current directory > is read-only, That's what this code is about. That is my initial impression when I wrote the patch; it was to do with Fossil creating the temp folder before writing to the file. This issue is a showstopper for those who use recent OpenBSD versions, as OpenBSD now has a symlink from /var/tmp to "../tmp", which confuses Fossil. The patch fixes this situation: $ cd /home/test/fossil/wdir1 $ fossil uv edit .... (try to create directory /home/test/fossil/wdir1/../tmp i.e. /home/test/fossil/tmp) > I sometimes use symlink support in fossil, but it shouldn't be fancy > at all. When committing a symlink, someone else checking it out > should get the same symlink. This - generally - only makes sense > when the symlink is relative and points to somewhere else in > the working directory. Otherwise - indeed - it doesn't make sense. > This is the way that - for example - Subversion handles symlinks, > it would be a loss to remove it from fossil. It's just like the 'x' > (executable) flag: unfortunate that Windows doesn't handle it the way > UNIX does, that's the reason why fossil has to do tricky things .... What Fossil should do is have a reliable way to determine what should be written first. A "racish" condition can exist with symlink support where files that go into a symlinked directory are written first, and when it's time to create the symlink, the name of the link itself is taken because Fossil has written the directory. > > That said, symlinks are actually a UNIX-only feature: I don't > mind that - on Windows - symlinks check-out as being a file with > the link path as content (that's what Subversion does as well ...) Since Windows Vista and Windows Server 2008: https://msdn.microsoft.com/en-us/library/windows/desktop/aa363866%28v=vs.85%29.aspx > > Regards, > Jan Nijtmans > _______________________________________________ > fossil-users mailing list > fossil-users@lists.fossil-scm.org > http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users _______________________________________________ fossil-users mailing list fossil-users@lists.fossil-scm.org http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users