about summary refs log tree commit diff
path: root/users/wpcarro/emacs
diff options
context:
space:
mode:
authorWilliam Carroll <wpcarro@gmail.com>2021-11-08T17·47-0800
committerwpcarro <wpcarro@gmail.com>2022-01-08T06·17+0000
commite0dbc1ae591cc6a4cc587fed5be29061c5fa4dd8 (patch)
tree43ff861c2b8c9c375510fcdbb0ccaa5ce23ade35 /users/wpcarro/emacs
parent07d1f9449bedebd545001a62f1d7eec34b104ced (diff)
feat(wpcarro/emacs): Pass --{hidden,follow} flags to rg r/3565
These are useful defaults.

Change-Id: Ife4a7f559c9599ba3b846eea7e757266afd7ceae
Reviewed-on: https://cl.tvl.fyi/c/depot/+/4805
Tested-by: BuildkiteCI
Reviewed-by: wpcarro <wpcarro@gmail.com>
Autosubmit: wpcarro <wpcarro@gmail.com>
Diffstat (limited to 'users/wpcarro/emacs')
-rw-r--r--users/wpcarro/emacs/.emacs.d/wpc/wpc-misc.el11
1 files changed, 5 insertions, 6 deletions
diff --git a/users/wpcarro/emacs/.emacs.d/wpc/wpc-misc.el b/users/wpcarro/emacs/.emacs.d/wpc/wpc-misc.el
index 58fc6a09c9..df0a7720f9 100644
--- a/users/wpcarro/emacs/.emacs.d/wpc/wpc-misc.el
+++ b/users/wpcarro/emacs/.emacs.d/wpc/wpc-misc.el
@@ -272,12 +272,11 @@
           (setq deadgrep--additional-flags '("--multiline"))
           (wpc-misc-deadgrep-region)
         (call-interactively #'deadgrep))))
-  (advice-add
-   'deadgrep--format-command
-   :filter-return
-   (lambda (cmd)
-     (replace-regexp-in-string
-      "^rg " "rg --hidden " cmd))))
+  (advice-add 'deadgrep--arguments
+              :filter-return
+              (lambda (args)
+                (push "--hidden" args)
+                (push "--follow" args))))
 
 ;; TODO: Do I need this when I have swiper?
 (use-package counsel)