I know how to add a new filetype to ack. This was answered here
For example, I added handlebars
:
--type-set=hbs=.hbs
However, I am unable to add a filetype containg a dot, such as for blade
--type-set=blade=.blade.php
If I search ack div --blade
then I get no results
You'll have to use ack 2.x's --type-set regex matching.
--type-set='blade:match:.blade.php$'
Look at the ack manual (ack --man
) under "Defining your own types" for details.
Take a look at ack --dump
to see other examples of matching.