reddit / emacs

How to TAB-complete ripgrep command-line options when typing in consult-ripgrep?

takutekato · 2022-12-16 07:35
Currently I am using a [`consult-ripgrep`](https://github.com/minad/consult#asynchronous-search) wrapper that inserts some sensible defaults options so my initial input looks like this: `#█ -- -g *.md -g !test/** --no-hidden --no-follow -U --sort path #` When I need to add another option, like: `#def -- -█ -g *.md -g !test/** --no-hidden --no-follow -U --sort path #` For a long one as `--ignore-file-case-insensitive`, having shell-like TAB completion definitely makes typing it more bearable, like what [https://github.com/szermatt/emacs-bash-completion](https://github.com/szermatt/emacs-bash-completion) provides in the screenshot for `shell-command` prompt. https://preview.redd.it/v5nvyh6uq76a1.png?width=953&format=png&auto=webp&s=8c1dab19d363a3f46ffdb83fa4cdbd57cd8e7f6c Searching suggested me [https://github.com/JonWaltman/pcmpl-args.el](https://github.com/JonWaltman/pcmpl-args.el), but after looking at the README, I still don't get how to use it.