% cat temp $$$ hello1 $$ hello2 hello3 ## hello4 hello5 $$$ % cat temp | grep \"$$$\" Illegal variable name. % cat temp | grep \"\\$\\$\\$\" Variable name
Works for me:
user@host:~$ cat temp | grep '\$\$\$' $$$ hello1 hello5 $$$ user@host:~$