-
-
22 Oct 2019 20:56:31 UTC
- Distribution: App-Packager
- Module version: 1.430
- Source (raw)
- Browse (raw)
- Changes
- How to Contribute
- Repository
- Issues (0)
- Testers (5 / 0 / 0)
- Kwalitee
Bus factor: 1- License: perl_5
- Perl: v5.10.1
- Activity
24 month- Tools
- Download (3.85KB)
- MetaCPAN Explorer
- Permissions
- Subscribe to distribution
- Permalinks
- This version
- Latest version
- Dependencies
- unknown
- Reverse dependencies
- CPAN Testers List
- Dependency graph
- NAME
- SYNOPSIS
- EXPORT
- FUNCTIONS
- App::Packager::GetResourcePath
- App::Packager::GetResource($rsc)
- App::Packager::GetUserFile($rsc)
- AUTHOR
- SUPPORT
- ACKNOWLEDGEMENTS
- COPYRIGHT & LICENSE
NAME
App::Packager - Abstraction for Packagers
SYNOPSIS
App::Packager provides an abstract interface to a number of common packagers, trying to catch as much common behaviour as possible.
The main purpose is to have uniform access to application specific resources.
Supported packagers are PAR::Packer, Cava::Packager and unpackaged. In the latter case, resources are looked up in @PATH, and the name of the application package must be passed to the first
use
of App::Packager.For example:
use App::Packager qw(:name My::App); print "My packager is: ", App::Packager::Packager(), "\n"; print getresource("README.txt");
EXPORT
By default, function
getresource
is exported. It can be exported under a different name by providing an alternative name as follows:use App::Packager( ':rsc' => '...alternative name...' );
FUNCTIONS
App::Packager::Packager
Returns the name of the actual packager, or
App Packager
if unpackaged.App::Packager::Version
Returns the version of the packager.
App::Packager::IsPackaged
Returns true if the application was packaged.
Note that it is usually easier, and safer, to use $App::Packager::PACKAGED for testing since that will work even if App::Packager is not available.
App::Packager::GetResourcePath
Returns the path name of the application resources directory.
App::Packager::GetResource($rsc)
Returns the file name of the application resource.
App::Packager::GetUserFile($rsc)
Returns the file name of the user specific resource.
AUTHOR
Johan Vromans,
<JV at CPAN dot org>
SUPPORT
Development of this module takes place on GitHub: https://github.com/sciurius/perl-App-Packager.
You can find documentation for this module with the perldoc command.
perldoc App::Packager
Please report any bugs or feature requests using the issue tracker on GitHub.
ACKNOWLEDGEMENTS
This module was inspired by Mark Dootson's Cava packager.
COPYRIGHT & LICENSE
Copyright 2017,2018 Johan Vromans, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
1 POD Error
The following errors were encountered while parsing the POD:
- Around line 253:
=back without =over
Module Install Instructions
To install App::Packager, copy and paste the appropriate command in to your terminal.
cpanm App::Packager
perl -MCPAN -e shell install App::Packager
For more information on module installation, please visit the detailed CPAN module installation guide.