$ emacsq.sh -P cl-lib,ivy --eval "\
(progn
(global-set-key (kbd \"C-c r\") 'counsel-rg)
(defun counsel-rg-search-in-result (_)
(ivy-read \"Search in result: \"
(cl-copy-list ivy--all-candidates)
:action #'counsel-grep-action))
(ivy-add-actions 'counsel-rg '((\"s\" counsel-rg-search-in-result \"Search In result\"))))" -nw
Steps:
- 运行上面的最小配置(
emacsq.sh)
- 按
C-c r
开始搜索 - 输入关键字
- 按
M-o
切换到 action 菜单界面 - 按
s
执行 Search in result