all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#37771: 26.3; doc for `dired-auto-revert-buffer'
@ 2019-10-15 22:35 Drew Adams
  2019-10-17  2:57 ` Lars Ingebrigtsen
  2019-10-17 17:08 ` Eli Zaretskii
  0 siblings, 2 replies; 4+ messages in thread
From: Drew Adams @ 2019-10-15 22:35 UTC (permalink / raw)
  To: 37771

Please consider improving the doc so that it does the following:

* Explains what is meant by "visiting" a Dired buffer.  The Emacs
  manuals and other doc only speak about visiting a file in a buffer.
  Just what constitutes "visiting" a Dired buffer?  It seems like it's
  sufficient to display the buffer and select its window.  Is that it?

* Explains the Value Menu items in Customize - in particular, item
  `Revert changed Dired buffer'.

* Explains that the option has no effect on Dired buffers containing
  arbitrary file lists (i.e., whose DIRNAME is a cons).  It is relevant
  only for actual directory listings.

* Lists the Lisp values that correspond to the Value Menu items.


In GNU Emacs 26.3 (build 1, x86_64-w64-mingw32)
 of 2019-08-29
Repository revision: 96dd0196c28bc36779584e47fffcca433c9309cd
Windowing system distributor `Microsoft Corp.', version 10.0.17763
Configured using:
 `configure --without-dbus --host=x86_64-w64-mingw32
 --without-compress-install 'CFLAGS=-O2 -static -g3''





^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#37771: 26.3; doc for `dired-auto-revert-buffer'
  2019-10-15 22:35 bug#37771: 26.3; doc for `dired-auto-revert-buffer' Drew Adams
@ 2019-10-17  2:57 ` Lars Ingebrigtsen
  2019-10-17 15:34   ` Drew Adams
  2019-10-17 17:08 ` Eli Zaretskii
  1 sibling, 1 reply; 4+ messages in thread
From: Lars Ingebrigtsen @ 2019-10-17  2:57 UTC (permalink / raw)
  To: Drew Adams; +Cc: 37771

Drew Adams <drew.adams@oracle.com> writes:

> Please consider improving the doc so that it does the following:
>
> * Explains what is meant by "visiting" a Dired buffer.  The Emacs
>   manuals and other doc only speak about visiting a file in a buffer.
>   Just what constitutes "visiting" a Dired buffer?  It seems like it's
>   sufficient to display the buffer and select its window.  Is that it?

It means whatever Emacs means by "visiting" a file.  I don't see what's
there to explain.

> * Explains the Value Menu items in Customize - in particular, item
>   `Revert changed Dired buffer'.

Explaining what "revert" means in this context seems a bit odd.  There's
a manual for that.

> * Explains that the option has no effect on Dired buffers containing
>   arbitrary file lists (i.e., whose DIRNAME is a cons).  It is relevant
>   only for actual directory listings.

You mean that switching it off doesn't stop reverting in that case?

	      ;; Always revert when `dir-or-list' is a cons.  Also revert
	      ;; if `dired-directory' is a cons but `dir-or-list' is not.
	      ((or (consp dir-or-list) (consp dired-directory))
	       (setq dired-directory dir-or-list)
	       (revert-buffer))
	      ;; Always revert regardless of whether it has changed or not.
	      ((eq dired-auto-revert-buffer t)
	       (revert-buffer))

As far as I can tell, this is only reached when you call `dired'
explicitly with a list of file names?  That dired updates the buffer
when you call it with a bunch of file names, without consulting
dired-auto-revert-buffer, seems pretty self-evident.

> * Lists the Lisp values that correspond to the Value Menu items.

They all seem documented?

          (const :tag "Revert changed Dired buffer" dired-directory-changed-p)

is just a predicate function.

Didn't see anything that needed fixing here, and I'm closing this bug
report.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#37771: 26.3; doc for `dired-auto-revert-buffer'
  2019-10-17  2:57 ` Lars Ingebrigtsen
@ 2019-10-17 15:34   ` Drew Adams
  0 siblings, 0 replies; 4+ messages in thread
From: Drew Adams @ 2019-10-17 15:34 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: 37771

> > Please consider improving the doc so that it does the following:
> >
> > * Explains what is meant by "visiting" a Dired buffer.  The Emacs
> >   manuals and other doc only speak about visiting a file in a buffer.
      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

> >   Just what constitutes "visiting" a Dired buffer?  It seems like
> >   it's sufficient to display the buffer and select its window.
> >   Is that it?
> 
> It means whatever Emacs means by "visiting" a file.  I don't see what's
> there to explain.

Why do you think so?  Nowhere in our doc do we introduce
a notion of "visiting" a buffer.  And a Dired buffer is
not a file.

Isn't what's really meant only that the buffer is displayed
and its window is selected?  If so, say so.  That's a far
cry from visiting a file.

> > * Explains the Value Menu items in Customize - in particular, item
> >   `Revert changed Dired buffer'.
> 
> Explaining what "revert" means in this context seems a bit odd.
> There's a manual for that.

No.  Buffer reverting is particular to different
kinds of buffer (apart from file buffers, where
it acts about the same for any file).  So explain
what it means to revert a Dired buffer.  And yes,
it means something particular.

> > * Explains that the option has no effect on Dired buffers containing
> >   arbitrary file lists (i.e., whose DIRNAME is a cons).  It is
> >   relevant only for actual directory listings.
> 
> You mean that switching it off doesn't stop reverting in that case?

Switching what off?  I don't know what you mean here.

The point is that reverting a Dired buffer means one
thing for a file listing (ordinary use of Dired).

It means something else when the buffer has any an
arbitrary list of files (e.g. from different dirs
that are not just subdirs).  In such cases IF
reverting is possible its behavior can be particular
to the particular kind of listing.  And this variable
does not apply - its value has no effect. 

> 	      ;; Always revert when `dir-or-list' is a cons.  Also revert
> 	      ;; if `dired-directory' is a cons but `dir-or-list' is not.
> 	      ((or (consp dir-or-list) (consp dired-directory))
> 	       (setq dired-directory dir-or-list)
> 	       (revert-buffer))
> 	      ;; Always revert regardless of whether it has changed or not.
> 	      ((eq dired-auto-revert-buffer t)
> 	       (revert-buffer))
> 
> As far as I can tell, this is only reached when you call `dired'
> explicitly with a list of file names?  That dired updates the buffer
> when you call it with a bunch of file names, without consulting
> dired-auto-revert-buffer, seems pretty self-evident.

Self-evident from the code.  The point is that the
_doc_ for the variable should say that it has no
effect in such cases - it applies only to ordinary
file listings, such as produced by `ls'.

> > * Lists the Lisp values that correspond to the Value Menu items.
> 
> They all seem documented?

No.  This one is not: "Revert changed Dired buffer".

> "Revert changed Dired buffer" dired-directory-changed-p)
> is just a predicate function.

Of course it is.  But it is a particular, predefined
predicate, which corresponds to one of the menu items.

This is no different from when we have menu items
that correspond to other particular values.  We
document them.  Users should be able to see the
correspondence between the documented Lisp values
and the menu items.

> Didn't see anything that needed fixing here, and I'm closing this bug
> report.

Unfortunate.





^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#37771: 26.3; doc for `dired-auto-revert-buffer'
  2019-10-15 22:35 bug#37771: 26.3; doc for `dired-auto-revert-buffer' Drew Adams
  2019-10-17  2:57 ` Lars Ingebrigtsen
@ 2019-10-17 17:08 ` Eli Zaretskii
  1 sibling, 0 replies; 4+ messages in thread
From: Eli Zaretskii @ 2019-10-17 17:08 UTC (permalink / raw)
  To: Drew Adams; +Cc: 37771

> Date: Tue, 15 Oct 2019 15:35:05 -0700 (PDT)
> From: Drew Adams <drew.adams@oracle.com>
> 
> Please consider improving the doc so that it does the following:

Thanks, fixed.





^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-10-17 17:08 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-10-15 22:35 bug#37771: 26.3; doc for `dired-auto-revert-buffer' Drew Adams
2019-10-17  2:57 ` Lars Ingebrigtsen
2019-10-17 15:34   ` Drew Adams
2019-10-17 17:08 ` Eli Zaretskii

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.