Re: command "find"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ulf-D. Ehlert skreiv:
> Kolbjørn Stuestøl (Dienstag, 25. März 2008, 21:54):
>   
>> The command "find src *.xml | xargs grep -E 'xxx' > xxx.txt" in
>> Cygwin Thanks to Julien for the tip :-) . The command is very fast
>> and I therefore prefer to use it.
>> But how to exclude files from the listings? Something like: "Find and
>> list all "xyz" in all xml files in all folders except in the .svn
>> folders". Perhaps an unfulfillable wish? The help in Cygwin was of no
>> help to me in this question.
>> Kolbjørn
>>     
>
> find src -name .svn -prune -o -name '*.xml' -print
>
> or (to exclude more than one directory)
>
> find src \( -name .svn -o -name foo \) -prune -o -name '*.xml' -print
>
> Ulf
>   
Hi Ulf
My wish was to sort out and list all xml files containing the word "xyz" 
(or whatever) in the src directory except for the files in the .svn 
folders.
I had to combine the two commands:
"find src -name '.svn' -prune -o -name '*.xml' -print | xargs grep -E 
'xyz' > xyz.txt"
As usual, if you omit the "> xyz.txt" the output goes to the screen 
instead of the text file.
(Fortunately Cygwin has a repeat command function).
Perhaps this command could be of some use to others.
Thanks to you and to Julien.
Kolbjørn
> ------------------------------------------------------------------------
>
> _______________________________________________
> Gimp-docs mailing list
> Gimp-docs@xxxxxxxxxxxxxxxxxxxxxx
> https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-docs
>   


_______________________________________________
Gimp-docs mailing list
Gimp-docs@xxxxxxxxxxxxxxxxxxxxxx
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-docs


[Index of Archives]     [Video For Linux]     [Yosemite News]     [gtk]     [GIMP for Windows]     [KDE]     [Scanners]     [GEGL]     [Gimp's Home]     [Gimp on Windows]     [Steve's Art]     [Webcams]

  Powered by Linux