On Saturday, April 27, 2002, at 10:26 , Tara Calishain wrote:
>
> I thought chdir would do the trick, but the files are still being written
> to directory A
> despite the fact that directory B appears to have been generated fine.
chdir merely changes where the process is... and would be
a reasonable idea.... assuming that you gave it an argument...
hence if you wrote to $filename and it winds up in A
and if your
$newdir = mkdir ("$DAY$realmonth$realyear");
{ what was the correct way to check that this worked?
per perldoc -f mkdir }
chdir $DAY$realmonth$realyear #what is the test that this workd?
why not try the presumption that
open(FH, "> $DAY$realmonth$realyear/$filename)
or die "unable to open $DAY$realmonth$realyear/$filename :$!\n";
might put the file in the correct directly.
note:
my $dirA = "some/path/here";
my $dirB = $dirA . $offset
hence you would be able to do
foreach (@list_shrugged) {
my $newfile = "$dirB/$_";
# fun stuff here
}
ciao
drieux
---
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]