| 제목 |
141 : [tip] 주석(#), 공백 라인을 제외하고 출력해보기 |
| 이름 |
산이 [홈]http://linuxchannel.net/ |
[tip] 주석(#), 공백 라인을 제외하고 출력해보기
grep -Ev '^[[:space:]]*(#|$)' < foobar
예)
grep -Ev '^[[:space:]]*(#|$)' < /etc/crontab
BASH)
grep -Ev '^[[:space:]]*(#|$)' < /etc/crontab ; // OK
grep -Ev "^[[:space:]]*(#|$)" < /etc/crontab ; // OK
CSH)
grep -Ev '^[[:space:]]*(#|$)' < /etc/crontab ; // OK
grep -Ev "^[[:space:]]*(#|$)" < /etc/crontab ; // FAIL |
|
2006년 01월 15일 19:22:51 일(저녁) from 58.231.28.56 |