App::Packager(3)

πŸ“¦
version 1.440 Β· 3 versions
, in fedora 43

πŸ’– App::Packager πŸ’–

okay bestie, gather round, because this is the App::Packager manual page β€” User Contributed Perl Documentation energy, and it's literally the abstraction layer for packagers. no cap. πŸŽ€


✨ NAME ✨

App::Packager β€” Abstraction for Packagers πŸ‘‘


🌸 SYNOPSIS 🌸

So App::Packager hands you an abstract interface to a whole bunch of common packagers, and the whole vibe is that it tries to catch as much common behaviour as possible. πŸ¦‹

The main purpose? uniform access to application specific resources. that's the moment, that's the whole point.

The supported packagers are PAR::Packer, Cava::Packager, and unpackaged. And when it's the unpackaged case, resources get looked up in @PATH, and the name of the application package must be passed to the first use of App::Packager. yes, must. no negotiating. πŸ’…

For example:

use App::Packager qw(:name My::App);
print "My packager is: ", App::Packager::Packager(), "\n";
print getresource("README.txt");

πŸ’« EXPORT πŸ’«

By default, the function getresource is exported. cute, right? And if you want it under a different name, you just hand over an alternative name like this:

use App::Packager( ':rsc' => '...alternative name...' );

🧚 FUNCTIONS 🧚

⭐ App::Packager::Packager

Returns the name of the actual packager, or "App Packager" if it's unpackaged.

⭐ App::Packager::Version

Returns the version of the packager. slay.

⭐ App::Packager::IsPackaged

Returns true if the application was packaged. 🫢

ngl bestie, it's usually easier and safer to test with $App::Packager::PACKAGED instead, because that one works even if App::Packager isn't available. lowkey important. 😭

⭐ 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>" β€” iconic.


🌈 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. we love a good issue tracker moment fr fr. πŸ“


πŸŽ€ ACKNOWLEDGEMENTS πŸŽ€

This module was inspired by Mark Dootson's Cava packager. shoutout. ✨


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.


πŸ’€ POD ERRORS πŸ’€

Hey! The above document had some coding errors, which are explained below:

Around line 286:

=back without =over

not the =back without =over jump scare 😭 the POD parser is in its flop era.


and that's the whole page, bestie!! πŸ¦‹ this was perl v5.42.0, dated 2025-07-25, and yes, it's App::Packager(3) β€” stay packaged, stay iconic, mwah πŸ’–

πŸ“¦ where this page comes from