Mailinglist Archive: opensuse-de (1962 mails)

< Previous Next >
Re: Kleines Skriptproblem
  • From: Dominik Klein <dk@xxxxxxxxxxxxxxxx>
  • Date: Tue, 1 Aug 2006 10:27:28 +0000 (UTC)
  • Message-id: <44CF2C7B.2050900@xxxxxxxxxxxxxxxx>
#find /test -mtime +30 -type f -print | grep -v Exclude1 | grep -v Exclude2 | cut -f2 -d\/ | sort -u > /tmp/LISTE
#
#for i in `cat /tmp/LISTE`; do
# echo $i
# rm -rf $i
#done

An und für sich klappt das ja.

Von daher noch ein anderer Ansatz:

Ersetze doch vor der Umleitung in /tmp/LISTE alle Leerzeichen durch mit einem Backslash entwertete Leerzeichen.

Also eine weitere pipe mit sed 's/ /\\\ /g'

Grüße
Dominik

< Previous Next >
References