码迷,mamicode.com
首页 > 其他好文 > 详细

perl的安装和版本切换工具-perlbrew

时间:2017-04-08 13:47:24      阅读:1939      评论:0      收藏:0      [点我收藏+]

标签:pen   lin   setenv   bre   tar   follow   append   new   should   

setenv PERL /opt/perl5 --设置新perl的起始安装路径

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

source /opt/perl5/perlbrew/etc/bashrc

perlbrew init
perlbrew root (/opt/perl5/perlbrew) is initialized.

Append the following piece of code to the end of your ~/.bash_profile and start a
new shell, perlbrew should be up and fully functional from there:

    source ~/perl5/perlbrew/etc/bashrc

Simply run `perlbrew` for usage details.

Happy brewing!


perlbrew install perl-5.16.0

perlbrew switch perl-5.16.0

至此,当前perl已经切换到新安装的perl-5.16.0

如果想再切换回旧版的,

source /opt/perl5/perlbrew/etc/bashrc

perlbrew switch-off

perl -v 查看当前版本已经切回。

完毕!

参考:http://perlbrew.pl/

perl的安装和版本切换工具-perlbrew

标签:pen   lin   setenv   bre   tar   follow   append   new   should   

原文地址:http://www.cnblogs.com/gordonchang/p/6681557.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!