Doom-emacs: Returning to a search

Created on 5 Jul 2018  路  5Comments  路  Source: hlissner/doom-emacs

Observed behavior

When I am searching in a project (SPC / p) and are visiting the result with RET the search is lost

Expected behavior

How can i get back the the search with the term i inserted?

System information

develop branch

:completion helm :completion ivy obsolete resolved

Most helpful comment

@paschdan (ivy-previous-history-element), bound to M-p usually.

All 5 comments

There is ivy-resume command which does exactly what you want if it is not called from another ivy interface, because in that case it would resume the current active one.
So you need to call it from evil-ex (: or SPC ;) or set up key binding for it. I've put it on SPC = as this is currently free key combination against doom's default config. Another possibility would be SPC R or SPC r r if you don't mind mixing it into remote prefix.

This is example of binding ivy-resume to SPC =:

(map!
 :leader
 :desc "resume latest ivy" :nv "=" #'ivy-resume
 )

edit: or if you just want to peak into files from SPC / p without editing them, you can press C-SPC while any candidate is highlighted. Pressing C-SPC few more time will execute recenter-top-bottom which could reveal few more additional lines.

nice, it dit not work when i tried to do ivy-resume from evil-ex (triggered with :) that's why i thought it is broken, i just missed the point, that by TAB in evil-ex i triggered another ivy 馃 馃敨
thanks for clearing this up for me.

coming back to this, the resume-ivy does not fix this issue completely. It works, as long as i do not use any other ivy command. But when i run some ivy commands in my workflow and want then come back to the search it is gone. Any other suggestion?

@paschdan (ivy-previous-history-element), bound to M-p usually.

Since no better solution than using history or ivy-resume exists at the moment (and should probably be requested upstream, rather than in Doom), I'll consider this resolved.

Was this page helpful?
0 / 5 - 0 ratings