1
0
Fork 0
mirror of https://github.com/perlbot/perlbuut synced 2025-06-08 05:15:41 -04:00
perlbuut/plugins/shorten.pm

14 lines
291 B
Perl

no warnings 'void';
sub {
my( $said, $pm ) = @_;
use WWW::Shorten::TinyURL;
use WWW::Shorten 'TinyURL';
print "New link: ", WWW::Shorten::TinyURL::makeashorterlink($said->{body}) // $said->{body};
}
__DATA__
shorten <url> returns the "short form" of a url. Defaults to using tinyurl.