counsel-ag: Ignore matches from files
ag supports the option
--ignore PATTERN to ignore files/directories whose names match the pattern. We could find a way to pass this command option in as a prefix argument.
As mentioned in searching and filtering by file name, I like to bind
(counsel-projectile-ag) to a common shortcut,
Super + f (or
s-f), so that I can pass the universal argument with
C-u to filter results.
Example: To search
coffee and ignore the matches in
org and markdown files, I would do:
--ignore *org --ignore *md
- Type search string
coffeeand press enter