MPATH(1)

πŸ“¦
version 0.19 Β· 4 versions
, in opensuse-leap 16.0

πŸ¦‹ mpath(1) β€” like, the manual page, bestie πŸ¦‹

okay so welcome to mpath, coming at you straight from the User Contributed Perl Documentation section of your friendly neighbourhood manual. she's a little one-trick pony and she does her trick flawlessly. let's get into it ✨


πŸ’– NAME πŸ’–

mpath β€” displays the full path to a perl module (the one installed locally on your machine, obvi πŸ’…)


🌸 USAGE 🌸

mpath [OPTIONS] MODULE [MODULE ...]

literally just hand her some module names and she'll hand you back paths. that's it. that's the vibe 🫢


πŸŽ€ EXAMPLE πŸŽ€

okay so here's her serving in the wild, no cap:

% mpath Module::Path
/usr/local/lib/perl5/site_perl/5.16.0/Module/Path.pm

% mpath --full Module::Path
Module::Path /usr/local/lib/perl5/site_perl/5.16.0/Module/Path.pm

% mpath Moose Moo
/usr/local/lib/perl5/site_perl/5.16.0/darwin-2level/Moose.pm
/usr/local/lib/perl5/site_perl/5.16.0/Moo.pm

see how the second one prints the module name and the path? that's the --full glow-up. and the third one? multiple modules, multiple lines, main character energy πŸ‘‘


✨ DESCRIPTION ✨

so mpath displays the full path to a perl module on the local system. she's not out here guessing β€” she uses the module_path() function from Module::Path to get the path. delegation, she invented it πŸ’…

now. if one of the modules wasn't found, mpath will exit with the exit code 1 and print the following message. and if that message is too much for you, you can silence it with the --quiet option:

% mpath Foo::Bar
Foo::Bar not found

or:

% mpath Moose Foo::Bar
/usr/local/lib/perl5/site_perl/5.16.0/darwin-2level/Moose.pm
Foo::Bar not found
bestie, notice how she still prints the ones she did find 😭 she's not gonna punish Moose for Foo::Bar's crimes. but the exit code is still 1, so keep an eye on that if you're scripting.

πŸ”₯ OPTIONS πŸ”₯

  • -h, -?, --help β€” prints this help message and exits. your girl is helpful 🫢
  • -f, --full β€” prints the module name. (alongside the path, iykyk)
  • -q, --quiet β€” don't print any error when one of the modules requested could not be found. silence is golden, periodt 🀫

🌈 SEE ALSO 🌈

  • Module::Path β€” the icon she's built on top of πŸ’œ

πŸ‘‘ AUTHOR πŸ‘‘

Neil Bowers <neilb@cpan.org> β€” legend behaviour, honestly 🌟


This software is copyright (c) 2012 by Neil Bowers <neilb@cpan.org>.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. slay πŸ’…


and that's the whole page, bestie!! this lil cutie is MPATH(1), dated 2015-04-13, generated with perl v5.42.0 β€” mwah, go find some modules πŸ§šπŸ’–

πŸ“¦ where this page comes from