[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#23033: 24.5; Lock file uses the same extension as the file it's lock
From: |
Stefan Kangas |
Subject: |
bug#23033: 24.5; Lock file uses the same extension as the file it's locking |
Date: |
Fri, 08 Nov 2019 06:00:14 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) |
Glenn Morris <rgm@gnu.org> writes:
> Michael Sloan wrote:
>
>> Lockfiles help the circumstance where multiple emacs processes are
>> editing the same file. The lockfile for 'File.hs' gets the name
>> '.#File.hs'. This means that naive enumeration of all the files in the
>> directory with the extension '.hs' will also yield the lockfile. Many
>> tools have behaviors that rely on enumerating all of the files which
>> have a particular extension, reasonably assuming that the user put them
>> there.
>
> It's very long-standing behaviour.
> So that we can assess how big the issue is, can you give some examples
> of the tools that have issues with this?
> As you say, it seems naive for a tool to simply find all files with a
> given extension, including dotfiles that are non-existent symlinks.
>
>> In particular, for me this caused the following issue:
>> https://github.com/commercialhaskell/stack/issues/1897
>
> Which you fixed the same day in the tool in question, right?
As much as I agree with the general sentiment above, one could also
consider users who are running e.g. 'find -iname "*.hs"' and are not
necessarily interested in seeing Emacs lock files. IOW, if this is
not a big change, it could be worth doing it. But it is mostly
cosmetic.
Best regards,
Stefan Kangas