I would like to search for lines which contains 2 (or more) specific words. For example I have multiple occurrences of
my function in project:
I would like to look only for those occurrences which contains
Any way of doing that using Sublime's
Find in files?
This RegEx pattern gives you a high degree of control over what characters are allowed within the function:
Alternatively, if you want a simpler match that finds any line which contains
my_function followed by
Or to match any line which contains both
nil, in any order, use:
Groups 1 & 5 contain escaped parentheses.
Groups 2 & 4 contain a character set that matches:
all alphanumeric characters, commas, underscores, single quotes, double quotes, & whitespace
More info @:
first press ctrl+shift+f then type in find and where with below query
Find: (string1|string2) Where: <path of the folder>
Find in files and enable Regular expressions (Alt+R shortcut).
Then use this regex to find the occurences