c*t
6 楼
1. find could do the job as well :) Mastering find is invaluable.
2. Learn to use backquote.
rm `ls -1 | grep mystr`
【在 F***Q 的大作中提到】![](/moin_static193/solenoid/img/up.png)
: I got it,thx
: but I still wonder how can I get the purpose by using ls as
: ls -1 | grep mystr
: which can list all of the files, then, how to delete them?
: only can find exec another command?
2. Learn to use backquote.
rm `ls -1 | grep mystr`
【在 F***Q 的大作中提到】
![](/moin_static193/solenoid/img/up.png)
: I got it,thx
: but I still wonder how can I get the purpose by using ls as
: ls -1 | grep mystr
: which can list all of the files, then, how to delete them?
: only can find exec another command?
t*l
7 楼
I think this won't work. should be
rm `ls -1 | xargs grep -l mystr`
rm `ls -1 | xargs grep -l mystr`
相关阅读
how to convert gb to big5?Can somebody tell me the meaning of each option in FFLAGS?windows编的Fortran程序在UNIX不work?How to use monitor of SGI work station on PC?[转载] Re: 怎样在英文solaris 8中设置中文?why my "biff" doesn't work?Cygwin问题请教re:How to check the stack-size?How to MATLAB in a 32-node Unix machine.Solaris Complile Problems每次登陆后总是弹出一个很讨厌的窗口,它藏哪呢?Re: Help: How to input an additional blank behind every line in VI?Help: How to input an additional blank behind every line in VI?How to check the stack-size?where does gdiff or xdiff lie in sb2000?为什么我看不见新的邮件how to copy /boot/boot1 to a: as bootset.bsd?Perl/Tk ,Tix???Help, What happen to Audio output when using ExceedHelp: One question about checksum in Unix