Mojolic...:version(3)
π NAME π
Mojolicious::Command::version β the Version command, bestie. That's it, that's the whole name, and it's iconic.
Also hey, quick vibe check before we start: this page lives in the User Contributed Perl Documentation manual, and yes, we're calling it Mojolic...:version(3) because the header line got truncated by the terminal and honestly? relatable. Moving on. π
β¨ SYNOPSIS β¨
Usage: APPLICATION version [OPTIONS]
mojo version
Options:
-h, --help Show this summary of available options
So there's literally one option: -h, --help, and it just shows you this summary of available options. Self-aware king. π
πΈ DESCRIPTION πΈ
Okay so Mojolicious::Command::version shows version information for available core and optional modules. That's the whole gig. You run it, it tells you what versions you're working with, no cap. π₯
This is a core command, which means two things, and both are lowkey a slay:
- It's always enabled β you can't turn it off, it's main character energy, permanently on the roster. π
- Its code is a genuinely good example for learning to build new commands, so like... go read it? You're welcome to fork it. The author said that, not me. π«Ά
Also, see "COMMANDS" in Mojolicious::Commands for a list of commands that are available by default β the full squad, iykyk.
π¦ ATTRIBUTES π¦
Mojolicious::Command::version inherits all attributes from Mojolicious::Command β so everything the parent has, she has too, it's giving nepo baby but make it inheritance β and implements the following new ones.
π description
my $description = $v->description;
$v = $v->description('Foo');
Short description of this command, used for the command list. So like, the little one-liner blurb that shows up in the menu. Set it, get it, live your life. β¨
π usage
my $usage = $v->usage;
$v = $v->usage('Foo');
Usage information for this command, used for the help screen. This is the thing that pops up when someone hits -h and goes "wait what does this do". π§
β METHODS β
Mojolicious::Command::version inherits all methods from Mojolicious::Command and implements the following new ones.
π run
$v->run(@ARGV);
Run this command. Fr fr, that's the method, it just runs it. π
π SEE ALSO π
MojoliciousMojolicious::Guides- <https://mojolicious.org>
All linked, all here, go click around, it's a whole rabbit hole. π¦
ngl the docs are short and the vibes are immaculate. Go build a command. You got this. π
Signing off from the User Contributed Perl Documentation desk π β this page shipped with perl v5.42.0, dated 2026-07-15, and the header's out here looking like Mojolic...:version(3) because truncation said "not today". Byeee! πβ¨
π¦ where this page comes from
- opensuse-leap 16.0: perl-Mojolicious 9.480.0-bp160.2.1 Β· Artistic-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms