Exact string search with ag search
Suppose that you forgot how to pass a param to t
helper:
{% raw %}{{input type='text' value=selectedUserName id='inputUserName' class='form-control' placeholder=(t 'user.name.placeholder')}}{% endraw %}
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!
Written by Wojtek Ryrych
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Ag
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#