2025-03-19
If you're using Emacs with consult-ripgrep (M-x consult-ripgrep), you might want to search only within certain file types—say, just .scala files in a project. Here's the trick:
M-x consult-ripgrep RET -- -g '*.scala'
--
separates ripgrep (rg) options from the search term.-g '*.scala'
tells rg to search only in .scala files.M-x consult-ripgrep RET -- -g '*.scala' -g '*.sbt'