CATALYST(1p)

πŸ“¦
version 5.90132 Β· 4 versions
, in debian trixie, ubuntu resolute, ubuntu stonking

πŸ’– CATALYST πŸ’–

okay bestie, listen up β€” this is the catalyst.pl page from the User Contributed Perl Documentation, and it's literally your onboarding pass to bootstrapping a whole Catalyst app. slay. let's go πŸ¦‹


✨ NAME ✨

catalyst β€” Bootstrap a Catalyst application 🌱


✨ SYNOPSIS ✨

catalyst.pl [options] application-name

catalyst.pl makes you a skeleton for a brand new application, and it also lets you upgrade the skeleton of an app you already have. two jobs, one script, main character energy πŸ’…

Options:

  • -force β€” don't create a .new file where a file to be created already exists πŸ™ˆ
  • -help β€” show this help and dip out, that's it
  • -makefile β€” only update Makefile.PL
  • -scripts β€” only update the helper scripts

kay so about that application-name β€” it has to be a valid Perl module name, no exceptions, and yes it can include ::, which gets converted to - in the project name. so cute, so convenient πŸ’–

Examples:

catalyst.pl My::App
catalyst.pl MyApp

Wanna upgrade your app to a newer version of Catalyst? bestie say less:

catalyst.pl -force -scripts MyApp

✨ DESCRIPTION ✨

The catalyst.pl script bootstraps a Catalyst application, creating a directory structure that's already populated with skeleton files. it's giving "instant structure, zero effort" ✨

The application name must be a valid Perl module name. the directory it makes is formed from the application name you gave it, with the double colons swapped out for hyphens β€” so like, for example, the directory for My::App is My-App. iconic conversion, honestly πŸŽ€

Using the example application name My::App, your shiny new application directory will contain these lil guys:

  • README β€” a skeleton README file, which you are encouraged to expand on. go off, write your docs πŸ“
  • Changes β€” a changes file with an initial entry for the creation of the application
  • Makefile.PL β€” uses the Module::Install system for packaging and distribution of the application
  • lib β€” contains the application module (My/App.pm) and subdirectories for model, view, and controller components (My/App/M, My/App/V, and My/App/C)
  • root β€” root directory for your web document content. this one is left empty πŸ«™
  • script β€” a directory containing helper scripts:
    • myapp_create.pl β€” helper script to generate new component modules
    • myapp_server.pl β€” runs the generated application inside a Catalyst test server, which you can use for testing without resorting to a full-blown web server configuration πŸ”₯
    • myapp_cgi.pl β€” runs the generated application as a CGI script
    • myapp_fastcgi.pl β€” runs the generated application as a FastCGI script
    • myapp_test.pl β€” runs an action of the generated application straight from the command line
  • t β€” test directory πŸ§ͺ

And the application module that catalyst.pl generates? it's fully functional out of the box, bestie. it just reacts to literally every request by outputting a friendly welcome screen 🌸


✨ NOTE ✨

okay this part matters, pay attention πŸ‘‘

Neither catalyst.pl nor the generated helper script will overwrite existing files. nope. instead, the scripts generate new versions of any existing files, tacking the extension .new onto the filename. and plot twist β€” the .new file is not created if it would be identical to the existing file. no pointless dupes here, we're efficient πŸ’…

So what does that mean for you? it means you can re-run the scripts to, for example, see if newer versions of Catalyst or its plugins generate different code, or to see how you may have changed the generated code yourself. (though obviously all your code is in a version control system anyway... right? right? πŸ‘€πŸ«Ά)


✨ SEE ALSO ✨

  • Catalyst::Manual
  • Catalyst::Manual::Intro

go read those, bestie, iykyk πŸ“š


✨ AUTHORS ✨

Catalyst Contributors, see Catalyst.pm πŸ‘‘


This library is free software, you can redistribute it and/or modify it under the same terms as Perl itself. πŸ“


and that's the whole page, bestie!! πŸ’– this one came to you courtesy of perl v5.40.0, dated 2024-11-15, filed under CATALYST(1p) ✨ go build something iconic, mwah πŸŽ€πŸ¦‹
πŸ“¦ where this page comes from