Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 5 Aug 2017 13:58:50 +0200
From:      Jos Chrispijn <bsduser@cloudzeeland.nl>
To:        freebsd-questions@freebsd.org
Subject:   Wildcard on redirection
Message-ID:  <25f022f4-4778-3f28-8d78-1f1b292f849e@cloudzeeland.nl>

next in thread | raw e-mail | index | archive | help
I have this number of .log files which I would like to empty.

Using

echo > *.log

unfortunately doesn't work so I created

foreach file in (/myfiles/log/*log)
   echo "" > $file
end

but that sequence is not recognized at all.

Can you tell me how to solve? Thanks!




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?25f022f4-4778-3f28-8d78-1f1b292f849e>