Rails is the latest and greatest web development platform in most people's eyes at this time. It has really changed how people perceive web development. Rails has brought an easy to use ORM to the masses. Its two main mottos are DRY and convention over configuration. This is exactly what makes Rails so simple. However, when want utter flexibility, speed, and vast number of extensions you should look else where; enter Catalyst.
Catalyst is a Perl based web framework. It features everything you would expect from a modern web MVC framework; template engine, an ORM, and RESTful URLs. The thing that sets Catalyst apart from Rails is choice, your free to use various components. You are not limited to a single component. For example, with Rails there is only ActiveRecord and that is all you get. However, with Catalyst your free to choose from DBIx::Class,Rose::DB::Object or the older Class::DBI. The same principle is applied to the template engine where you have access to five various template engines. The down side to all this is the initial take off time. Basically the learning curve is longer than with Rails.
Let's get started on working with Catalyst. First off, you need to understand how to use CPAN. CPAN is the equivalent of rubygems. I will list some comparisons of cpan and rubygems.
Catalyst / Perl |
Rails / Ruby |
Searching the module networks
|
bash$ cpan
cpan> i /catalyst/
|
bash$ gem search -r rails
|
| Installing Modules |
bash$ cpan
cpan> install Task::Catalyst
|
bash$ gem install -r rails
|
| Upgrading Modules |
bash$ cpan
cpan> r
|
bash$ gem update
|
| View Installed Modules |
bash$ perldoc perllocal
|
bash$ gem list
|
| Uninstall Modules |
bash$ cpanp # Using CPANPLUS
CPAN Terminal> u Task::Catalyst
|
bash$ gem uninstall rails
|
CPAN and RubyGems are very alike. RubyGems has the better upgrade functionality and uninstall while CPAN does not even have an uninstall command! When it comes down to volume of software/modules in the repositories CPAN wins hands down. CPAN contains over 10,000 Perl modules while RubyGems only has 1,718! CPAN has been around a lot longer and there are more Perl than Ruby programmers out there.
If you want to search for perl documentation or CPAN modules check out search.cpan.org