Commit c99c9ec2 authored by Wolfgang Scherer's avatar Wolfgang Scherer Committed by Lars Ingebrigtsen

Provide facility to ignore all marked files in vc

* lisp/vc/vc-dir.el: (vc-dir-ignore) With prefix argument, ignore all
marked files (bug#37240).
parent f198a5c5
Pipeline #3136 failed with stage
in 90 minutes and 2 seconds
...@@ -743,6 +743,10 @@ file. ...@@ -743,6 +743,10 @@ file.
*** New customizable variable 'vc-find-revision-no-save'. *** New customizable variable 'vc-find-revision-no-save'.
With non-nil, 'vc-find-revision' doesn't write the created buffer to file. With non-nil, 'vc-find-revision' doesn't write the created buffer to file.
---
*** 'vc-dir-ignore' now takes a prefix argument to ignore all marked
files.
*** New customizable variable 'vc-git-grep-template'. *** New customizable variable 'vc-git-grep-template'.
This new variable allows customizing the default arguments passed to This new variable allows customizing the default arguments passed to
'git-grep' when 'vc-git-grep' is used. 'git-grep' when 'vc-git-grep' is used.
......
...@@ -864,10 +864,18 @@ with the command \\[tags-loop-continue]." ...@@ -864,10 +864,18 @@ with the command \\[tags-loop-continue]."
delimited) delimited)
(fileloop-continue)) (fileloop-continue))
(defun vc-dir-ignore () (defun vc-dir-ignore (&optional arg)
"Ignore the current file." "Ignore the current file.
(interactive) If a prefix argument is given, ignore all marked files."
(vc-ignore (vc-dir-current-file))) (interactive "P")
(if arg
(ewoc-map
(lambda (filearg)
(when (vc-dir-fileinfo->marked filearg)
(vc-ignore (vc-dir-fileinfo->name filearg))
t))
vc-ewoc)
(vc-ignore (vc-dir-current-file))))
(defun vc-dir-current-file () (defun vc-dir-current-file ()
(let ((node (ewoc-locate vc-ewoc))) (let ((node (ewoc-locate vc-ewoc)))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment