Ardour has around 800k lines of code, and ag (not even the fastest of the new greps) can search it all more or less faster than I can type.
The idea of some system that analyzes/caches/indexes the code just isn't necessary anymore.
Somehow I never twigged that you wrote Ardour and JACK. Thanks for JACK! (My audio editing needs are very modest and so I haven't actually tried Ardour.)
first search ts, tsx, js, jsx files in the current project. Exclude .git, node_modules...
then search node_modules with the ts.. extensions, still exclude .git
finally search the whole tree for .py files still exclude .git, /dist...
This is coupled with consult-find-grep. I basically want to find a string in the most relevant file type. I never want a result from node_modules first in the results. It took some work, but the results are quite nice!
(find "$projroot" -name .git -prune -o -name node_modules -prune -o \
\( -name '*.[tj]s' -o -name '*.[tj]sx' \) -print0 ;
find "$projroot"/node_modules \
\( -name '*.[tj]s' -o -name '*.[tj]sx' \) -print0 ;
find "$projroot" -name .git -prune -o -name dist -prune -o \
\( -name '*.py' \) -print0 ) |
xargs -0 grep /dev/null "$search_pattern"
And, although that approach does work (and maybe even that script will work without any bug fixes) it probably goes a substantial distance toward showing why fd was written.Doing the three searches separately and exiting after one succeeds is only slightly more code.
and
https://github.com/paddymul/emacs-from-scratch/blob/master/p...
The emacs-lisp for changing the behaviour of consult-grep was quite complex and took a while to write.
Apparently I've sometimes improvised an equivalent: "Run grep via find, with user-specified args COMMAND-ARGS. ... This command uses a special history list for its arguments, so you can easily repeat a find command."
My out-of-the-box autocomplete is M-/, which works in environments where LSP doesn't, like writing English. It works sort of poorly in all of them, but I write production code slowly enough that my typing speed isn't close to being a bottleneck. It's more of a bottleneck when writing English, but even there, generally any of my good writing was good rewriting.
Where I've found LSP-like functionality really useful in the past in IDEA and later Eclipse was not autocomplete, which is mostly an annoyance, but in automated refactoring (extract variable, extract method, inline method) and in rapidly iterating through the implementors of a method whose semantics I'm changing.