diff options
Diffstat (limited to 'projectile.el')
| -rw-r--r-- | projectile.el | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/projectile.el b/projectile.el index bba0923..3a0eaff 100644 --- a/projectile.el +++ b/projectile.el @@ -1372,14 +1372,15 @@ If `command' is nil or an empty string, return nil. This allows commands to be disabled. Only text sent to standard output is taken into account." - (when (stringp command) - (let ((default-directory root)) - (with-temp-buffer - (let ((stderr-buffer (current-buffer))) - (with-temp-buffer - (shell-command command t stderr-buffer) - (let ((shell-output (buffer-substring (point-min) (point-max)))) - (split-string (string-trim shell-output) "\0" t)))))))) + (save-window-excursion + (when (stringp command) + (let ((default-directory root)) + (with-temp-buffer + (let ((stderr-buffer (current-buffer))) + (with-temp-buffer + (shell-command command t stderr-buffer) + (let ((shell-output (buffer-substring (point-min) (point-max)))) + (split-string (string-trim shell-output) "\0" t))))))))) (defun projectile-adjust-files (project vcs files) "First remove ignored files from FILES, then add back unignored files." |
