mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2025-01-21 18:23:59 +00:00
* vc.el (vc-dired-ignorable-p, vc-dired-hook): Speed optimization;
use completion-ignored-extensions to detect files that should be ignorted in VC-Dired listings, heading off lots of expensive calls to (vc-state).
This commit is contained in:
parent
1be05f120f
commit
35d33ce769
@ -1,3 +1,10 @@
|
||||
2007-12-27 Eric S. Raymond <esr@snark.thyrsus.com>
|
||||
|
||||
* vc.el (vc-dired-ignorable-p, vc-dired-hook): Speed optimization;
|
||||
use completion-ignored-extensions to detect files that should be
|
||||
ignorted in VC-Dired listings, heading off lots of expensive calls
|
||||
to (vc-state).
|
||||
|
||||
2007-12-27 Vinicius Jose Latorre <viniciusjl@ig.com.br>
|
||||
|
||||
* ps-print.el (ps-mark-active-p): Fun returned back.
|
||||
@ -6,8 +13,8 @@
|
||||
|
||||
2007-12-27 Eric S. Raymond <esr@snark.thyrsus.com>
|
||||
|
||||
* (vc.el, vc-sccs.el, vc-rcs.el, vc-cs.el, vc-mcvs.el): Put
|
||||
machinery in place to support editing of change comments
|
||||
* vc.el, vc-sccs.el, vc-rcs.el, vc-cs.el, vc-mcvs.el: Put
|
||||
new machinery in place to support editing of change comments
|
||||
with 'e' in a log-view buffer. Not documented yet as this
|
||||
only works for SCCS, RCS, and maybe CVS if you have admin
|
||||
privileges. When we have backend support for Subversion and
|
||||
|
16
lisp/vc.el
16
lisp/vc.el
@ -2327,6 +2327,16 @@ This code, like dired, assumes UNIX -l format."
|
||||
(replace-match (substring (concat vc-info " ") 0 10)
|
||||
t t nil 1)))
|
||||
|
||||
(defun vc-dired-ignorable-p (filename)
|
||||
"Should FILENAME be ignored in VC-Dired listings?"
|
||||
(catch t
|
||||
(dolist (ignorable completion-ignored-extensions)
|
||||
(let ((ext (substring filename
|
||||
(- (length filename)
|
||||
(length ignorable)))))
|
||||
(if (string= ignorable ext) (throw t t))))
|
||||
nil))
|
||||
|
||||
(defun vc-dired-hook ()
|
||||
"Reformat the listing according to version control.
|
||||
Called by dired after any portion of a vc-dired buffer has been read in."
|
||||
@ -2372,7 +2382,11 @@ Called by dired after any portion of a vc-dired buffer has been read in."
|
||||
(t
|
||||
(vc-dired-reformat-line nil)
|
||||
(forward-line 1))))
|
||||
;; ordinary file
|
||||
;; try to head off calling the expensive state query -
|
||||
;; ignore object files, TeX intermediate files, and so forth.
|
||||
((vc-dired-ignorable-p filename)
|
||||
(dired-kill-line))
|
||||
;; ordinary file -- call the (possibly expensive) state query
|
||||
((and (vc-backend filename)
|
||||
(not (and vc-dired-terse-mode
|
||||
(vc-up-to-date-p filename))))
|
||||
|
Loading…
Reference in New Issue
Block a user