diff options
| -rw-r--r-- | lisp/dired-x.el | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lisp/dired-x.el b/lisp/dired-x.el index 462fa4ee152..313a22725c7 100644 --- a/lisp/dired-x.el +++ b/lisp/dired-x.el | |||
| @@ -827,6 +827,7 @@ Also useful for `auto-mode-alist' like this: | |||
| 827 | ;; install GNU zip's version of zcat. | 827 | ;; install GNU zip's version of zcat. |
| 828 | 828 | ||
| 829 | (autoload 'Man-support-local-filenames "man") | 829 | (autoload 'Man-support-local-filenames "man") |
| 830 | (autoload 'vc-responsible-backend "vc") | ||
| 830 | 831 | ||
| 831 | (defvar dired-guess-shell-alist-default | 832 | (defvar dired-guess-shell-alist-default |
| 832 | (list | 833 | (list |
| @@ -909,7 +910,10 @@ Also useful for `auto-mode-alist' like this: | |||
| 909 | '(concat "znew" (if dired-guess-shell-gzip-quiet " -q") | 910 | '(concat "znew" (if dired-guess-shell-gzip-quiet " -q") |
| 910 | " " dired-guess-shell-znew-switches)) | 911 | " " dired-guess-shell-znew-switches)) |
| 911 | 912 | ||
| 912 | '("\\.patch\\'" "cat * | patch") | 913 | (list "\\.patch\\'" |
| 914 | '(if (eq (ignore-errors (vc-responsible-backend default-directory)) 'Git) | ||
| 915 | "cat * | git apply" | ||
| 916 | "cat * | patch")) | ||
| 913 | (list "\\.patch\\.g?z\\'" "gunzip -qc * | patch" | 917 | (list "\\.patch\\.g?z\\'" "gunzip -qc * | patch" |
| 914 | ;; Optional decompression. | 918 | ;; Optional decompression. |
| 915 | '(concat "gunzip" (if dired-guess-shell-gzip-quiet " -q"))) | 919 | '(concat "gunzip" (if dired-guess-shell-gzip-quiet " -q"))) |