bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#34911: 26.1; doc about lock file names


From: Drew Adams
Subject: bug#34911: 26.1; doc about lock file names
Date: Tue, 19 Mar 2019 07:54:48 -0700 (PDT)

> > I don't see documented anywhere what a lock file name looks like.
> > I looked through both the Emacs manual and the Elisp manual.  Did I miss
> > it somehow, or is it defined/described nowhere?
> 
> It is described in the node "File Locks" in the ELisp manual.

I started there.  I see nothing in that node that says
what the name looks like.  I'm using Emacs 26.  Did
someone perhaps add a description of it since that
release?

> > Please let users know what how lock files are named.  Thx.  If this is
> > already done somewhere, please refer to that location from node (elisp)
> > `File Locks'.
> 
> The node "Interlocking" in the user manual, where file locking is
> described on the user level, has a cross-reference to the above node
> pf ELisp manual.  So I'm unsure how you missed that.

Please explain how that replies to the text you quote,
or to any of the text in the bug report?  AFAICT, there
is nothing in the Emacs manual (including of course the
node you cite) or in the Elisp manual (including the node
you cite) that tells you how lock files are named.

That's what this bug report is about (and its near-duplicate,
#25469, also touches on this lack).  

> > Please also update the doc of `dired-omit-files' to make clear that its
> > default value only approximately matches auto-save files (and lock
> > files?), and that even this is true only for the default naming regime
> > for auto-save files.
> 
> I don't understand this part.  Concretely, what is missing in the doc
> string, and why do you think it is necessary to add whatever is
> missing?

The default value is "^\\.?#\\|^\\.$\\|^\\.\\.$".

\\.?# matches only the first char of an auto-save file
name, and the first two chars of a lock file name.  It
does not match the full name, requiring it to end with
`#'.  That means that (1) it cannot be used as is for,
say, font-locking such a (complete) name, and (2) as
it is now, it can falsely identify files that are not
auto-save or lock files.

And it does not necessarily match auto-save file names
at all, as they can be nearly anything, it seems:

(elisp) `Auto-Saving' makes a point of saying that each
of  `auto-save-file-name-p' and `make-auto-save-file-name'
exists "so that you can customize it if you wish to change
the naming convention for auto-save files".  And for each
it reminds us "If you redefine it, be sure to redefine the
[other] function ... correspondingly."

IOW, apparently the `#...#' is conventional but users are
practically invited to adopt alternative naming schemes.

While those two functions go together, so that changing
the naming scheme for one calls for changing it also for
the other, there are other functions and variables that
presume the standard naming convention.  Their doc does
not, so far, speak to the possibility of a naming change.

Also, please add a doc string for `dired-omit-regexp',
referring to `dired-omit-files' (where this missing doc
will hopefully be added) and `dired-omit-extensions', as
is done for `dired-mark-omitted', for example.

Does this clarify what I meant by "the default value only
approximately matches auto-save files (and lock files?)"?





reply via email to

[Prev in Thread] Current Thread [Next in Thread]