Skip Menu |

This queue is for tickets about the CPANPLUS CPAN distribution.

Report information
The Basics
Id: 5864
Status: resolved
Priority: 0/
Queue: CPANPLUS

People
Owner: Nobody in particular
Requestors: gdunham [...] fas.harvard.edu
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 0.049
Fixed in: (no value)



Subject: Problem saving configuration changes when using PERL5_CPANPLUS_CONFIG
I’m using CPANPLUS as a non root user to install modules to a custom location in my user account. First things first CPANPLUS rocks! I really like the new features and am promoting it to the other developers in my department. Now back to our regularly scheduled bug. I’m using a custom configuration file (~/.cpanplus/config) by setting PERL5_CPANPLUS_CONFIG. When I make a change to my settings, do a ‘s save’, exit and restart the shell my changes are lost. I did a little poking around and found my changes they were save to a file name ‘1’ in my current directory not ~/.cpanplus/config. After looking at the code I think the problem is in Configure.pm sub _load_cpanplus_config { my $tried; if ( defined $ENV{PERL5_CPANPLUS_CONFIG} ) { eval qq[require q|$ENV{PERL5_CPANPLUS_CONFIG}|]; $tried++; $INC{'CPANPLUS/Config.pm'} = 1 unless $@; } I changed: $INC{'CPANPLUS/Config.pm'} = 1 unless $@; To this: $INC{'CPANPLUS/Config.pm'} = $ENV{PERL5_CPANPLUS_CONFIG} unless $@; and ‘s save’ worked correctly. Cheers, Gayle Gayle Dunham gdunham@fas.harvard.edu 617-384-7763 ICG Developer Instructional Computing Group http://icg.fas.harvard.edu/ Faculty of Arts and Sciences Computer Services Harvard University PS System Info: CPANPLUS-0.049.tar.gz This is perl, v5.8.0 built for i386-linux-thread-multi Linux us04 2.4.20-20.9smp #1 SMP Mon Aug 18 11:32:15 EDT 2003 i686 i686 i386 GNU/Linux
Subject: Problem saving configuration changes when using PERL5_CPANPLUS_CONFIG
I’m using CPANPLUS as a non root user to install modules to a custom location in my user account. First things first CPANPLUS rocks! I really like the new features and am promoting it to the other developers in my department. Now back to our regularly scheduled bug. I’m using a custom configuration file (~/.cpanplus/config) by setting PERL5_CPANPLUS_CONFIG. When I make a change to my settings, do a ‘s save’, exit and restart the shell my changes are lost. I did a little poking around and found my changes they were save to a file name ‘1’ in my current directory not ~/.cpanplus/config. After looking at the code I think the problem is in Configure.pm sub _load_cpanplus_config { my $tried; if ( defined $ENV{PERL5_CPANPLUS_CONFIG} ) { eval qq[require q|$ENV{PERL5_CPANPLUS_CONFIG}|]; $tried++; $INC{'CPANPLUS/Config.pm'} = 1 unless $@; } I changed: $INC{'CPANPLUS/Config.pm'} = 1 unless $@; To this: $INC{'CPANPLUS/Config.pm'} = $ENV{PERL5_CPANPLUS_CONFIG} unless $@; and ‘s save’ worked correctly. Cheers, Gayle Gayle Dunham gdunham@fas.harvard.edu 617-384-7763 ICG Developer Instructional Computing Group http://icg.fas.harvard.edu/ Faculty of Arts and Sciences Computer Services Harvard University PS System Info: CPANPLUS-0.049.tar.gz This is perl, v5.8.0 built for i386-linux-thread-multi Linux us04 2.4.20-20.9smp #1 SMP Mon Aug 18 11:32:15 EDT 2003 i686 i686 i386 GNU/Linux
Thanks for the report, and fixed with patch 10457, which will be in the next release.