[pm-h] pm-uninstall - For uninstalling Perl Modules in a sane manner
G. Wade Johnson
gwadej at anomaly.org
Wed Jun 18 12:49:54 PDT 2014
Ooo, Nice.
I hadn't seen that before.
G. Wade
On Wed, 18 Jun 2014 19:08:38 +0000 (GMT)
Robert Stone via Houston <houston at pm.org> wrote:
> Greetings,
>
> I found myself needing to uninstall a few modules today and
> historically I would just navigate to the site perl install in my
> perlbrew and rm -rf the relevant files, hoping that nothing else was
> sharing the namespace:
>
>
>
> [rstone at rstone 5.16.3]$ pwd
> /home/rstone/perl5/perlbrew/perls/perl-5.16.3/lib/site_perl/5.16.3
> [rstone at rstone 5.16.3]$ rm -rf Bad/Module/
> [rstone at rstone 5.16.3]$
>
>
>
>
> I came across a blog post at
> http://scratching.psybermonkey.net/2011/02/perl-how-to-uninstall-delete-perl.html
> that talks about pm-uninstall, a program similar to cpanm that takes
> care of this task much more efficiently. It lists out what is going
> to be removed, mentions the deps, and handles man page updates (for
> those who use perldoc locally) as well as asks for conformation:
>
>
>
>
> [rstone at rstone product]$ cpanm App::pmuninstall
> --> Working on App::pmuninstall
> Fetching
> http://www.cpan.org/authors/id/X/XA/XAICRON/App-pmuninstall-0.30.tar.gz ...
> OK Configuring App-pmuninstall-0.30 ... OK Building and testing
> App-pmuninstall-0.30 ... OK Successfully installed
> App-pmuninstall-0.30 1 distribution installed
> [rstone at rstone product]$ pm-uninstall Math::Pari Math::BigInt::Pari
> --> Working on Math::Pari
> Math::Pari is included in the distribution Math-Pari and contains:
>
> /home/rstone/perl5/perlbrew/perls/perl-5.16.3/lib/site_perl/5.16.3/x86_64-linux/Math/Pari.pm
> /home/rstone/perl5/perlbrew/perls/perl-5.16.3/lib/site_perl/5.16.3/x86_64-linux/Math/PariInit.pm
> /home/rstone/perl5/perlbrew/perls/perl-5.16.3/lib/site_perl/5.16.3/x86_64-linux/Math/libPARI.dumb.pod
> /home/rstone/perl5/perlbrew/perls/perl-5.16.3/lib/site_perl/5.16.3/x86_64-linux/Math/libPARI.pod
> /home/rstone/perl5/perlbrew/perls/perl-5.16.3/lib/site_perl/5.16.3/x86_64-linux/auto/Math/Pari/Pari.so
> /home/rstone/perl5/perlbrew/perls/perl-5.16.3/man/man3/Math::Pari.3
> /home/rstone/perl5/perlbrew/perls/perl-5.16.3/man/man3/Math::PariInit.3
> /home/rstone/perl5/perlbrew/perls/perl-5.16.3/man/man3/Math::libPARI.3
> /home/rstone/perl5/perlbrew/perls/perl-5.16.3/man/man3/Math::libPARI.dumb.3
>
> Also, they're depended on by the following installed dists:
>
> Math-BigInt-Pari
>
> Are you sure you want to uninstall Math-Pari? [n] y
>
> Successfully uninstalled Math::Pari
>
> --> Working on Math::BigInt::Pari
> Math::BigInt::Pari is included in the distribution Math-BigInt-Pari
> and contains:
>
> /home/rstone/perl5/perlbrew/perls/perl-5.16.3/lib/site_perl/5.16.3/Math/BigInt/Pari.pm
> /home/rstone/perl5/perlbrew/perls/perl-5.16.3/man/man3/Math::BigInt::Pari.3
>
> Are you sure you want to uninstall Math-BigInt-Pari? [y] y
>
> Successfully uninstalled Math::BigInt::Pari
>
> You may want to rebuild man(1) entries. Try `mandb -c` if needed
>
> [rstone at rstone product]$
>
>
>
>
> I found it quite handy and thought I'd share it for anyone else who
> may find themselves in a similar position. I'm also open to any other
> similar tools/methods you may have used in the past.
>
>
>
>
> Happy uninstalling!
>
>
>
>
> Best Regards,
>
> Robert Stone
--
Any time things appear to be going better, you have overlooked
something.
More information about the Houston
mailing list