On 15/10/15 17:18, Pádraig Brady wrote:
> On 15/10/15 16:13, Jim Meyering wrote:
>> Here's a small improvement:
> 
>>  # Strip that part off for the following comparison.
>>  clean_rm_err_()
>>  {
>> -  sed "s/.*rm: /rm: /; \
>> -       s/\(rm: it is dangerous to operate recursively on\).*$/\1 '\/'/"
>> +  sed 's,.*\(rm: it is dangerous to operate recursively on\).*$,\1 '"'/',"
>>  }

Actually I'm not sure the combined works as we need
to match against multiple lines starting with "rm:..."
See "exp" below in the script.

thanks,
Pádraig.


Reply via email to