After a long break, the unix_quote fortune bot is back online. It is posing linux fortune command results from an Ubuntu server. The script is written in perl using the Net::Twitter::Lite library and is run using cron several times a day.
#!/usr/bin/perl use Net::Twitter::Lite; my $nt=Net::Twitter::Lite->new( legacy_lists_api => 1, consumer_key => "", consumer_secret => "", access_token => "", access_token_secret => "", ); $quote=`/usr/games/fortune`; $qupte=substr($quote,0,139); $quote =~ s/\s+$//; $nt->update($quote);
Of course, the secret passwords have been omitted to protect the innocent. The magic Oath passwords can be obtained from the twitter developer site.