A piggy bank of commands, fixes, succinct reviews, some mini articles and technical opinions from a (mostly) Perl developer.

The best way to embed code snippets in your blogger posts

Use gist.github.com

That is all.

Its very easy, its hosted by Github.
I like git.

Guide to debugging Mojolicious applications

When MOJO_MODE=development or is not set, you should see exceptions rendered in the browser. But if you don't, try creating a templates/exception.html.ep template that contains this: %= $exception

You can also create error templates for different environments:
  • templates/exception.production.html.ep
  • templates/exception.development.html.ep

Mojo provides useful hooks that can be used to dump out debugging info:

How to use local::lib to install Perl modules locally

First:

cd project_dir
eval $( perl -Mlocal::lib=local )

Install dependencies:

cpanm -L local --installdeps .

Or individual modules:

cpanm -L local Some::Module