Sample Header Ad - 728x90

How to make ag search "non-standard" langauge files?

1 vote
0 answers
145 views
I'm using Silver Searcher, ag, version 2.1.0 on Ubuntu. I'm trying to search for the string aStar in Haskell files in the current directory tree. (The files are text files with extension .hs.) The behaviour isn't what I expect.
$ ag aStar
finds no matches.
ag --haskell aStar
finds no matches.
ag --haskell --all-text aStar
finds the correct matches in the .hs files.
ag --all-text aStar
finds the correct matches in .hs files, plus a bunch in some temporary files I don't want searched. Any suggestions on what I'm doing wrong, and why the --haskell flag doesn't make ag search the Haskell files?
Asked by Neil Smith (111 rep)
Jan 1, 2020, 03:05 PM