James wrote:
>
> hi, all!
Hello,
> friday while trying to clean up a directory, i thought i
> could bang out a quick-and-dirty perl script that would
> let me achieve what i needed, to delete all text files in
> a subdirectory that contain a specified string. i was able
> to use the perl comman
t tested these yet, but you get the idea...
-Original Message-
From: james [mailto:[EMAIL PROTECTED]]
Sent: Monday, July 15, 2002 12:52 PM
To: [EMAIL PROTECTED]
Subject: unlinking all files that contain a specified string
hi, all!
friday while trying to clean up a directory, i thought i could ban
IL PROTECTED]>
Sent: Monday, July 15, 2002 4:13 PM
Subject: Re: unlinking all files that contain a specified string
> What about (assuming *nix)
>
> use strict;
>
> my $search_string = "Whatever you want to find";
>
> my @found = `grep -ls $search_string *`;
> chom
: <[EMAIL PROTECTED]>
Sent: Monday, July 15, 2002 3:51 PM
Subject: unlinking all files that contain a specified string
hi, all!
friday while trying to clean up a directory, i thought i could bang out a
quick-and-dirty perl script that would let me achieve what i needed, to
delete all text file
hi, all!
friday while trying to clean up a directory, i thought i could bang out a
quick-and-dirty perl script that would let me achieve what i needed, to delete all
text files in a subdirectory that contain a specified string. i was able to use the
perl command unlink(filename) and grep manua