find /home/ -name "*.[ch]" | xargs grep main
/home/ 디렉토리에서 main 이라는 글자가 들어간 파일을 검색하려고 할때
위와 같은 명령어를 사용하거든요.
그런데 main 같은 단어가 아니라, 문장을 검색하려면 어떻게 해야하죠?
super main 처럼 띄어쓰기가 있는 문장을 검색하는 방법 좀 가르쳐주세요!!
find /home/ -name "*.[ch]" | xargs grep "super main"
텍스트 포맷에 대한 자세한 정보
<code>
<blockcode>
<apache>
<applescript>
<autoconf>
<awk>
<bash>
<c>
<cpp>
<css>
<diff>
<drupal5>
<drupal6>
<gdb>
<html>
<html5>
<java>
<javascript>
<ldif>
<lua>
<make>
<mysql>
<perl>
<perl6>
<php>
<pgsql>
<proftpd>
<python>
<reg>
<spec>
<ruby>
<foo>
[foo]
find /home/ -name "*.[ch]" |
댓글 달기