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

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

bug#22694: 25.0.91; dired-mark-files-containing-regexp read file disk


From: Tino Calancha
Subject: bug#22694: 25.0.91; dired-mark-files-containing-regexp read file disk
Date: Sun, 10 Apr 2016 16:02:59 +0900 (JST)
User-agent: Alpine 2.20 (LRH 67 2015-01-07)


Let me argue more about why i found more useful if we change the current behaviour:

Let's suppose the following case:

1) An user submit several hundred of jobs to a batch server.

2) The output consist of just log files (1 per job) which are written
   under the submission directory until the jobs succeded of fail.
   When the job fails, the logfile contains the word 'aborting'.

3) To resubmit the failed jobs, the user may put all logfiles together in a
   dired buffer using `find-name-dired'.  From time to time, he/she call
   `dired-mark-files-containing-regexp' using 'aborting' as regexp: from this,
   he/she obtain directly the list of failed jobs...

4) ...But if the user has opened some of the logfiles from failed jobs, the word
   'aborting' may not be in the buffer (the user need to revert it first), so 
the
   list of failed jobs at 3) will not be exhaustive.  This behaviour is not
   consistent with the doc. string of the function:

"Mark all files with contents containing REGEXP for use in later commands.
A prefix argument means to unmark them instead.
`.' and `..' are never marked."

 - As mentioned in 4) this function may not mark all files containing
   REGEXP and this is not obvious unless you read the source code.

 - Just from the doc. string i would expect this function behaves as in
   the patch within this thread.

 - Using the buffer when available seems like an optimization but
   in fact it's not because it may produce different results.

 I suggest in order of preference:

A) Apply the patch in this thread: then, the funcion behaves as described in 
the doc. string.

B) Modify the doc. string to account for the case when there are buffers 
visiting the files.






reply via email to

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