Search code examples
perlenvironmentmultiple-versionsperlbrew

Is there a non-global equivalent of perlbrew?


I'm using perlbrew right now to manage multiple versions of perl, but perlbrew is global. If I do perlbrew switch perl-5.10.1 in any shell, then all shells and scripts will now be using perl version 5.10.1. There is no isolation. Is there any way to make perlbrew switches local to a shell, or is there a similar tool capable of locally changing the active perl?


Solution

  • In more recent versions of Perlbrew, you can do perlbrew use perl-5.12.3 or whatever and you'll be using that version of Perl, but only in the current shell session. Other sessions won't be affected.