in reply to Re: How to remove a module?
in thread How to remove a module?

Funny story about cpanp, unless you install a module with cpanp, which leaves a log in ....cpanplus/install-logs, you can't uninstall a module using cpanp

You first have to install it using cpanp , if it is already installed, you have to cpanp i MODULE --force

I found out after I deleted my install-logs directory

Replies are listed 'Best First'.
Re^3: How to remove a module?
by marto (Cardinal) on Mar 21, 2011 at 18:07 UTC

    Hmm, I just got home and read your post. Using cpan I:

    Then using cpanp:

    CPAN Terminal> u HTML::Template --force --verbose [MSG] No 'C:\Documents and Settings\marto\Application Data\.cpanplus\c +ustom-sour ces' dir, skipping custom sources [MSG] No 'C:\Documents and Settings\marto\Application Data\.cpanplus\c +ustom-sour ces' dir, skipping custom sources [MSG] No 'C:\Documents and Settings\marto\Application Data\.cpanplus\c +ustom-sour ces' dir, skipping custom sources Uninstalling 'HTML::Template' [MSG] Unlinking 'C:\strawberry\perl\site\lib\HTML\Template.pm' Running [C:\strawberry\perl\bin\perl.exe -eunlink+q[C:\strawberry\perl +\site\lib\ HTML\Template.pm]]... [MSG] Unlinking 'C:/strawberry/perl/site/lib/auto/HTML/Template/.packl +ist' Running [C:\strawberry\perl\bin\perl.exe -eunlink+q[C:/strawberry/perl +/site/lib/ auto/HTML/Template/.packlist]]... [MSG] Removing 'C:\strawberry\perl\site\lib\HTML' Running [C:\strawberry\perl\bin\perl.exe -e rmdir q[C:\strawberry\perl +\site\lib\ HTML]]... Module 'HTML::Template' uninstalled successfully All modules uninstalled successfully

    And tested it via:

    C:\>perl -e "use HTML::Template" Can't locate HTML/Template.pm in @INC (@INC contains: C:/strawberry/pe +rl/site/li b C:/strawberry/perl/vendor/lib C:/strawberry/perl/lib .) at -e line 1 +. BEGIN failed--compilation aborted at -e line 1.

    Looks like it worked as expected.

      LOL, that's awesome, I did not try to force uninstall, pure genius
Re^3: How to remove a module?
by John M. Dlugosz (Monsignor) on Mar 22, 2011 at 02:38 UTC
    Actually, it worked for me.