Posts Tagged ‘cpan’

WebService::MobileMe uploaded to the CPAN

Sunday, July 26th, 2009

Just a quick post to announce a new perl module I uploaded to the CPAN the other day. It’s still to be considered alpha quality as it is lacking error checking and other such necessary stuffs but is working for me.

Usage looks like:

use WebService::MobileMe;

my $mme = WebService::MobileMe->new(
    username => 'yaakov', password => 'HUGELOVE' );
my $location = $mme->locate;
print < <"EOT";
    As of $location->{date}, $location->{time}, Yaakov was at
    $location->{latitude}, $location->{longitude} (plus or minus
    $location->{accuracy} meters).
EOT
$mme->sendMessage( message => 'Hi Yaakov!', alarm => 1 );

The online documentation is available via search.cpan.org.

Git Web: http://git.thegrebs.com/?p=WebService-MobileMe
Git Clone: http://git.thegrebs.com/git/WebService-MobileMe

Module::Signature Rocks My Socks

Sunday, June 1st, 2008

Just discovered the perl module Module::Signature by 唐鳳 (Audrey Tang) the other day. It’s pretty spiffy.

Implementing is easy (stolen from the docs):

MakeMaker:

    WriteMakefile(
        (MM->can('signature_target') ? (SIGN => 1) : ()),
        # ... original arguments ...
    );

Module::Build:

   Module::Build->new(
        (sign => 1),
        # ... original arguments ...
    )->create_build_script;

Don’t forget to add

SIGNATURE

to your

MANIFEST

if needed.

Then when running

make dist

you will be prompted for the pass phrase for your gpg key. For extra goodness, add 0-signature.t to your tests. It includes a single test that verifies the package cryptographically during

make test

if the

TEST_SIGNATURE

environment variable is set.

If you know waltman and haven’t heard of this module, yell at him for not telling you about it, he’s mentioned in the

AUTHORS

file for his stellar documentation patches.