jump to navigation

Springcleaning: App::Unix::RPasswd March 25, 2011

Posted by claudio in Uncategorized.
Tags: , , ,
add a comment

It’s spring again, so I decided to prepare programs and libraries that are generic enough for CPAN.

App::Unix::RPasswd is the first candidate. App::Unix::RPasswd (remote passwd) is an application for changing passwords on UNIX and UNIX-like servers on a simple, fast (in parallel) and secure (SSH-keys) way. A salt-based retrievable “random” password generator, tied to the supplied server names and date, is included. The generated passwords, unique for each server, can be generated and automatically applied remotely. Because the salt is secret and the correct date string is required, the password for a specific server can only be regenerated by authorized personnel.

Perl 5.10 or higher is required. All recent GNU/Linux distribution have a recent perl (>= 5.10). In case you need it on Solaris 10, you can follow this howto to build a recent Perl (the best option in my view) or get precompiled packages from SunFreeware, Blastwave or OpenCSW.

Get it from CPAN:

cpan App::Unix::RPasswd

App::cpanminus: zero-conf CPAN client December 10, 2010

Posted by claudio in Uncategorized.
Tags: , , , , , ,
2 comments

App::cpanminus (cpanm) is an other great example of programs inscribed in the Modern Perl philosophy. From the CPAN page of the program:

cpanminus is a script to get, unpack, build and install modules from CPAN.

Why? It’s dependency free, requires zero configuration, and stands alone. When running, it requires only 10MB of RAM.

Zero configuration sounds excellent considering the rather steep learning of the (great!) CPAN tools (the cpan command line utility CPAN.pm and CPANPLUS) for new Perl users.

How does it work? Let try a big module with a lot of dependencies and C++ compiling activity. Install the application through cpan if configured (or with one of the standalone installations options):

$ cpan App::cpanminus
[...]

$ cpanm Moose
--> Working on Moose
Fetching http://search.cpan.org/CPAN/authors/id/D/DR/DROLSKY/Moose-1.21.tar.gz ... OK
Configuring Moose-1.21 ... OK
==> Found dependencies: Try::Tiny, Package::DeprecationManager, Test::Requires, Class::MOP, Sub::Exporter, Test::Fatal, Sub::Name, Data::OptList, Params::Util, List::MoreUtils, Task::Weaken
--> Working on Try::Tiny
[...]
Building and testing Moose-1.21 ... OK
Successfully installed Moose-1.21

$ perl -MMoose -e1

No errors. The modules (and their dependencies) installed just fine. Wow.

CPAN on Ubuntu fails on bug IO/Uncompress/RawInflate.pm: solution May 30, 2008

Posted by claudio in Uncategorized.
Tags: , , , , ,
13 comments

apt-gettable perl modules on Ubuntu are great. A nice packager at Debian Gnu/Linux compiled the modules and included all dependencies specially for you :) .

This is extremely handy when you are looking for a solution for a programming problem that you know someone else solved before. You apt-get the modules you need and have a quick try.

While doing exactly this (tryng to install HTML::TextToHTML) , I discover CPAN on Ubuntu was broken:” Can’t call method “value” on an undefined value at /usr/share/perl5/IO/Uncompress/RawInflate.pm line 64.”.

I don’t think it’s a Debian/Ubuntu problem, but rather a upstream bug. Some people have the same problem on Windows. How nice the apt-gettable modules are, there are always cases when you need to build modules not yet in the Ubuntu repositories or you need a newer version (both cases here). A non-working CPAN is not acceptable. This is what I did. (more…)

Follow

Get every new post delivered to your Inbox.

Join 127 other followers