App-Install
view release on metacpan or search on metacpan
lib/App/Install.pm view on Meta::CPAN
Permissions for the installed files are set as follows:
Foo::Bar::Install->permissions(
'foo.cgi' => 0755,
);
You'll generally do this straight after listing the files to install.
Only non-default permissions need to be specified; the default will be
whatever your system generally creates files as, eg. 0644 for readable
by everyone, writable by owner. See the docs for C<chmod()> for more
information.
=head2 Including variable data in your files
If you wish data to be interpolated into your inline files -- and you
probably do -- this is done using Text::Template. In its simplest form,
simply put anything you wish to have interpolated in triple curly braces:
package {{{$app_name}}};
lib/App/Install.pm view on Meta::CPAN
print " $outfile\n";
} else {
warn "Couldn't open $outfile} to write: $!\n";
}
}
sub _set_permissions {
my ($file) = @_;
return unless $file;
printf " Setting permissions for %s to %lo\n", $file, $App::Install::permissions{$file};
chmod $App::Install::permissions{$file}, $file;
}
=head1 AUTHOR
Kirrily "Skud" Robert, C<< <skud at cpan.org> >>
=head1 BUGS
Please report any bugs or feature requests to
C<bug-app-install at rt.cpan.org>, or through the web interface at
( run in 0.534 second using v1.01-cache-2.11-cpan-496ff517765 )