AnyEvent-Superfeedr
view release on metacpan or search on metacpan
eg/print_feed_titles.pl view on Meta::CPAN
use strict;
use warnings;
use Find::Lib '../lib';
use AnyEvent::Superfeedr;
use Encode;
die "$0 <jid> <pass>" unless @ARGV >= 2;
binmode STDOUT, ":utf8";
my $end = AnyEvent->condvar;
my $sf = AnyEvent::Superfeedr->new(
debug => $ENV{DEBUG},
jid => shift,
password => shift,
# bogus for my tests
#subscription => {
# interval => 5,
# sub_cb => sub { [ "firehoser.superfeedr.com" ] },
eg/status_feed.pl view on Meta::CPAN
use strict;
use warnings;
use Find::Lib '../lib';
use AnyEvent::Superfeedr;
use Encode;
die "$0 <jid> <pass>" unless @ARGV >= 2;
binmode STDOUT, ":utf8";
my $end = AnyEvent->condvar;
my $sf = AnyEvent::Superfeedr->new(
jid => shift,
password => shift,
on_notification => sub {
my $notification = shift;
printf "Fetched '%s' %s [status=%s], next at %s\n",
$notification->title,
$notification->feed_uri,
( run in 0.517 second using v1.01-cache-2.11-cpan-3cd7ad12f66 )