[REBOL] Re: check me? deleting files based on a pattern
From: joel:neely:fedex at: 28-Oct-2003 10:01
Hi, Tom,
Saving some typing and evaluation...
Tom Foster wrote:
> home: to-file rejoin ["~" "/"]
>
> base: to-file rejoin [home "attempt-it/"]
>
> foreach file read base [
> if found? (find file "editpost") [
> delete base/:file
> ]
> ]
>
You can just use a literal FILE! value for the base directory
foreach file read base: %~/attempt-it/ [...[
and avoid all the REJOIN evaluations.
-jn-
--
----------------------------------------------------------------------
Joel Neely joelDOTneelyATfedexDOTcom 901-263-4446
Enron Accountingg in a Nutshell: 1c=$0.01=($0.10)**2=(10c)**2=100c=$1