Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re^2: interactive mode cpan. "cpan" doesn't work. "perl -MCPAN -e shell" does

by Jeri (Scribe)
on Feb 12, 2014 at 20:51 UTC ( #1074690=note: print w/replies, xml ) Need Help??


in reply to Re: interactive mode cpan. "cpan" doesn't work. "perl -MCPAN -e shell" does
in thread interactive mode cpan. "cpan" doesn't work. "perl -MCPAN -e shell" does

haha really?
  • Comment on Re^2: interactive mode cpan. "cpan" doesn't work. "perl -MCPAN -e shell" does

Replies are listed 'Best First'.
Re^3: interactive mode cpan. "cpan" doesn't work. "perl -MCPAN -e shell" does
by Jeri (Scribe) on Feb 12, 2014 at 21:05 UTC
    Thanks, sorry. It seemed complicated. Need to take a break.

      Dude :) yes really

      When you install modules that install perl "EXE_FILES" their shebang gets rewritten to point to the perl doing the installing

      If you uninstall/remove/delete... that perl but the "EXE_FILE" that was installed using that perl remains ... this case your "cpan" file ... then its probably pointing to the wrong perl, one which doesn't exist ... thus the error message ( from your shell )

      So, cheapest way to fix it, is remove the offending file

      At this point, if the other perl is in your path, trying to execute cpan should call the new perls cpan file which will have the correct shebang for the new perl and call the correct perl

      If this isn't the case, and there just is no cpan file anymore, this is where reinstalling CPAN module comes in, it will install cpan EXE_FILE with correct shebang

      You can always look inside the "cpan" file you're trying to execute to see the paths it contains

      cpan probably isn't the only file with the wrong shebang

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1074690]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (2)
As of 2018-08-20 06:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Asked to put a square peg in a round hole, I would:









    Results (190 votes). Check out past polls.

    Notices?