This means that the " | head -n 200" speed-up isn't used and full
candidates are returned.
(do-grep (eq (ivy-state-caller ivy-last) 'counsel-git-grep)))
(with-current-buffer buffer
(if do-grep
- (ivy-occur-grep-mode)
+ (progn
+ (setq ivy--old-cands
+ (split-string
+ (shell-command-to-string
+ (format counsel-git-grep-cmd ivy--old-re))
+ "\n"
+ t))
+ (ivy-occur-grep-mode))
(ivy-occur-mode))
(setf (ivy-state-text ivy-last) ivy-text)
(setq ivy-occur-last ivy-last)