Mercurial > emacs
comparison lisp/dired-x.el @ 18917:347133072016
(dired-omit-new-add-entry): Take new arg RELATIVE
and pass it to dired-omit-old-add-entry (which is dired-add-entry).
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Wed, 23 Jul 1997 02:51:06 +0000 |
parents | 6f9fa4c8e92a |
children | 6044f0be20eb |
comparison
equal
deleted
inserted
replaced
18916:d4ff695d4034 | 18917:347133072016 |
---|---|
657 (let ((fn (dired-get-filename localp t))) | 657 (let ((fn (dired-get-filename localp t))) |
658 (and fn (string-match regexp fn)))) | 658 (and fn (string-match regexp fn)))) |
659 msg))) | 659 msg))) |
660 | 660 |
661 ;;; REDEFINE. | 661 ;;; REDEFINE. |
662 (defun dired-omit-new-add-entry (filename &optional marker-char) | 662 (defun dired-omit-new-add-entry (filename &optional marker-char relative) |
663 ;; This redefines dired-aux.el's dired-add-entry to avoid calling ls for | 663 ;; This redefines dired-aux.el's dired-add-entry to avoid calling ls for |
664 ;; files that are going to be omitted anyway. | 664 ;; files that are going to be omitted anyway. |
665 (if dired-omit-files-p | 665 (if dired-omit-files-p |
666 ;; perhaps return t without calling ls | 666 ;; perhaps return t without calling ls |
667 (let ((omit-re (dired-omit-regexp))) | 667 (let ((omit-re (dired-omit-regexp))) |
676 (t | 676 (t |
677 (dired-make-absolute | 677 (dired-make-absolute |
678 filename | 678 filename |
679 (file-name-directory filename))))))) | 679 (file-name-directory filename))))))) |
680 ;; if it didn't match, go ahead and add the entry | 680 ;; if it didn't match, go ahead and add the entry |
681 (dired-omit-old-add-entry filename marker-char) | 681 (dired-omit-old-add-entry filename marker-char relative) |
682 ;; dired-add-entry returns t for success, perhaps we should | 682 ;; dired-add-entry returns t for success, perhaps we should |
683 ;; return file-exists-p | 683 ;; return file-exists-p |
684 t)) | 684 t)) |
685 ;; omitting is not turned on at all | 685 ;; omitting is not turned on at all |
686 (dired-omit-old-add-entry filename marker-char))) | 686 (dired-omit-old-add-entry filename marker-char relative))) |
687 | 687 |
688 ;;; REDEFINE. | 688 ;;; REDEFINE. |
689 ;;; Redefine dired-aux.el's version of `dired-add-entry' | 689 ;;; Redefine dired-aux.el's version of `dired-add-entry' |
690 ;;; Save old defun if not already done: | 690 ;;; Save old defun if not already done: |
691 (or (fboundp 'dired-omit-old-add-entry) | 691 (or (fboundp 'dired-omit-old-add-entry) |