diff --git a/deadgrep.el b/deadgrep.el index a9eb5a2..fb43af3 100644 --- a/deadgrep.el +++ b/deadgrep.el @@ -1698,12 +1698,17 @@ don't actually start the search." (buffer-file-name)))) (last-results-buf (car-safe (deadgrep--buffers))) prev-search-type - prev-search-case) + prev-search-case + prev-skip-if-hidden + prev-skip-if-vcs-ignore) ;; Find out what search settings were used last time. (when last-results-buf + ;; here certainly (with-current-buffer last-results-buf (setq prev-search-type deadgrep--search-type) - (setq prev-search-case deadgrep--search-case))) + (setq prev-search-case deadgrep--search-case) + (setq prev-skip-if-hidden deadgrep--skip-if-hidden) + (setq prev-skip-if-vcs-ignore deadgrep--skip-if-vcs-ignore))) (funcall deadgrep-display-buffer-function buf) @@ -1716,7 +1721,9 @@ don't actually start the search." ;; search results buffer. (when last-results-buf (setq deadgrep--search-type prev-search-type) - (setq deadgrep--search-case prev-search-case)) + (setq deadgrep--search-case prev-search-case) + (setq deadgrep--skip-if-hidden prev-skip-if-hidden) + (setq deadgrep--skip-if-vcs-ignore prev-skip-if-vcs-ignore)) (deadgrep--write-heading)