Exact string search with ag search

Suppose that you forgot how to pass a param to t helper:

{{input type='text' value=selectedUserName id='inputUserName' class='form-control' placeholder=(t 'user.name.placeholder')}}

The easiest way is to search for similar usage in your project:

ag "\(t \'" -G .hbs$

Escaping is boring, but ag allows you to leave \\ with wit -Q option:

ag -Q '(t ' -G .hbs

ag is faster then ack and grep. If you want to use ag in vim, use this repo:

Plug 'rking/ag.vim'

Have fun!

This protip has been written in 829 seconds