notes -x *.git/ -x *.png
in general if you want to exclude hidden files and folders you need to run it with -h true which excludes hidden dirs and files, so you can run notes -h true -x *.png notes -x *.git/ -x *.png
in general if you want to exclude hidden files and folders you need to run it with -h true which excludes hidden dirs and files, so you can run notes -h true -x *.pngIt is for the same reason that `rg`/`ag`/`pt` are used nowadays instead of `grep`. 99.99% of the time, you don't want to search files that are ignored by your VCS, and you want to search recursively, and also probably in a case-insensitive way. For `grep` you have to fight with tons of options to filter out files, to enable recursivity and to ignore case. With `ag`? just `ag whatever`.
Defaults make the difference.
const BAD_EXTENSIONS = ["!*.jpg", "!*.jpeg", "!*.mov", "!*.mp3", "!*.gif", "!*.png", "!*.log", "!*.bin", "!*.psd", "!*.swf", "!*.fla", "!*.ico"];
I was wondering why `.png` was scanned. However, your comment makes so much sense and it will be wise to add default folders like .git as wellThanks a lot for that, ill be looking forward to what defaults people also want to have :)
PS: Another idea: Instead of selecting manually what extensions should be used or not, you may want to try being more general, like enabling by default all text-like files, and disabling all data-like files. Maybe with `file --mime` then looking at charset value:
test.jpg: image/jpeg; charset=binary
manage.py: text/x-python; charset=us-ascii notes -i *.py
I hope this helps :)Thanks for the pointer
Example:
rm -rf *