Syntax for sed .. altered?

Marco Atzeri marco.atzeri@gmail.com
Thu Jun 30 17:22:00 GMT 2016



On 30/06/2016 16:57, Fergus Daly wrote:
>>>> find dirname -type f | xargs sed -i 's/string1/string2/g'
>>>> .. just hangs.
>>>  sed is unchanged from at least 2013, so it must be something else.
>>   Is is possible that this is related to a change in the Cygwin library?
>
> Thank you very much for your interest.
> I was premature in my assertion that sed "hangs".
> But it takes a crazy crazy time.
> I was working on a directory of 6000 text files when I reported as above.
> This is what happened with a directory of <90 files:
>
> ~> find archive -type f | wc
>      87      87    1698
> ~> time find archive -type f | xargs sed -i 's/string1/string2/g'
> real    1m2.587s
> user    0m1.200s
> sys     0m12.884s
>
> More than a minute for 90 files is just extraordinary.
> Anybody else having a similar experience?
> (Thank you again.)
>
> Fergus
>

Not at all

$ find test -type f |wc
     177     177    5119

$ time find test -type f | xargs sed -i -e "s/Octave/Pippo/g"

real    0m5.149s
user    0m0.170s
sys     0m1.183s


BLODA ?





--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple



More information about the Cygwin mailing list