Twitter + Bash == Bad Idea
#!/usr/bin/perl -w use strict; use warnings; use Net::Twitter; my $bot = Net::Twitter->new( username => "username", password => "password" ); chomp(my $doing = <>); $doing =~ s/^\s+\d+\s+//; $bot->update($doing);
To make it ‘useful’ you’ll need to run the following in your bash shell:
PROMPT_COMMAND='history | tail -n 1 |
/path/to/twitter_post.pl' and tada! People really will know what
you’re doing RIGHT NOW. Ahem, sorry.