Permalink
Find file
Fetching contributors…
Cannot retrieve contributors at this time
executable file 24 lines (14 sloc) 488 Bytes
#!/usr/bin/perl
# Sneaky way to get more information in your tweets
use strict;
use warnings;
use utf8;
sub tweet_compress {
my $tweet = shift;
my @orig = ( qw/cc ms ns ps in ls fi fl ffl ffi iv ix vi oy ii xi nj/, '. ', ', ' );
my @new = qw/㏄ ㎳ ㎱ ㎰ ㏌ ʪ fi fl ffl ffi ⅳ ⅸ ⅵ ѹ ⅱ ⅺ nj . ,/;
$tweet =~ s/\Q$orig[$_]\E/$new[$_]/g for 0 .. $#orig;
return $tweet;
}
binmode STDOUT, ':utf8';
print tweet_compress( join '', @ARGV ), "\n";