I have recently discovered ack and ack -ir --ignore-dir={node_modules,dist,.git} <search-term>
works great for most things but this
---node_modules/
---------------project1/
-----------------------node_modules/
---------------project2/
-----------------------node_modules/
I would like to search all files under the "root" node_modules and excluding all internal ones.
Note: if I run find . -type f | ack -v 'node_modules|.git|dist'
under the root node_modules folder, I get a proper file list. this happen because find .
gives out relative paths. Any way to feed this list to ack ?