ps -ef | grep hoge | grep -v grep
Doing like this gives the same result.
ps -ef | grep [h]oge
Because regexp like /[h]oge/ matches "*hoge*" and does not match "[h]hoge" that is the argument of grep command.
seratch's programming memo
ps -ef | grep hoge | grep -v grep
ps -ef | grep [h]oge
0 件のコメント:
コメントを投稿