--- lib/PXElator/file.pm 2009/08/26 08:59:50 291 +++ lib/PXElator/file.pm 2009/08/26 09:06:10 292 @@ -77,8 +77,10 @@ die "no destination" unless $to; return if -e $to; mkpath $to; - carp "# copy_once $from => $to"; + my $perm = (stat $from)[2]; + carp "# copy_once $from => $to $perm"; write_file $to, read_file($from); + chmod $perm, $to; } 1;