Another Japan in the World

Jun Aruga's blog.

Set up Perl development environment

In this article, I used perlbrew (perl version management tool).

Perlbrew

$ curl -kL http://install.perlbrew.pl | bash

Add these lines to .bash_profile

$ vi ~/.bash_profile

# Perlbrew
if [ -f ~/perl5/perlbrew/etc/bashrc ]; then
    . ~/perl5/perlbrew/etc/bashrc
fi
$ . ~/.bash_profile

"perl-5.21.2" is sample.

$ perlbrew available
$ perlbrew install perl-5.21.2

Add these lines to .bashrc

$ vi ~/.bashrc

# Perl
if which perlbrew > /dev/null; then
    perlbrew switch perl-5.21.2
    echo "Now using Perl 5.21.2 by perlbrew"
fi
$ . ~/.bashrc
$ which perl
$HOME/perl5/perlbrew/perls/perl-5.21.2/bin/perl

cpanm

Better CPAN management tool. It can manage CPAN modules by user unit.

Install cpanm to under the home directory.

$ curl -L http://cpanmin.us | perl - App::cpanminus
$ which cpanm
$HOME/perl5/perlbrew/perls/perl-5.21.2/bin/cpanm

http://gihyo.jp/dev/serial/01/perl-hackers-hub/002102

Carton

Perl package management tool. It can manage CPAN modules by project directory unit.

$ cpanm Carton

$ which carton
$HOME/perl5/perlbrew/perls/perl-5.21.2/bin/carton

$ carton -v
carton v1.0.12

http://gihyo.jp/dev/serial/01/perl-hackers-hub/002103

PerldocJp

Perldoc Japanese version. For Japanese engineer ;p

$ cpanm Pod::PerldocJp
$ perldocjp perl

Perltidy

Perl formatting tool.

$ cpanm Perl::Tidy

$ which perltidy
$HOME/perl5/perlbrew/perls/perl-5.21.2/bin/perltidy