i'm looking search files via ssh grep command have special chars. string i'm looking is: "$globals['....'];"
tried one
grep -r -h "\$globals\\['*'\\]\;" /var/www/ but nothing happens. welcome.
your re matches "$globals['''''''];" 1 or more ' there. try one:
grep -rhp "[$]globals\['.*?']\;" file i use [$] instead of \$, because escape somehow tricky, environment need use \\\$.
update, less 10 chars inside []:
grep -rhp "[$]globals\['.{0,10}']\;" file
Comments
Post a Comment