Everyone knows of the now infamous google malware database corruption. Google was able to fix the issue quickly, which is great and all. But what really impresses me is their open attitude when it comes to their end user products, like this post on the gmail blog.
You may be a big headless giant robot, but you're our big headless giant robot.
Wednesday, February 04, 2009
Sunday, January 11, 2009
Renaming MP3 by ID tag
Ever tried to recover from an IPOD dump, and get a bunch of files with the useless names? Here's a script to fix that.
And here's the perl script:
$ ls *.mp3 | ./rename.pl - | while read line; do OLD=`echo $line | cut -d, -f1`; NEW=`echo $line | cut -d, -f2`; mv "$OLD" "$NEW"; done
And here's the perl script:
#!/usr/bin/perl
#
#Your Love Means Everything.mp3: (tag v1.0)
#songname: Your Love Means Everything
#artist: Coldplay
#album: Varie
#year:
#comment:
#genre: Other(12)
#
while( <> )
{
chomp;
my %hsh = ();
my @info = `id3ed -i "$_"`;
foreach my $iline ( @info )
{
chomp $iline;
#print $iline . "\n";
if( $iline =~ /songname:\s+\b(.+?)$/ ){
$hsh{ song } = $1;
}
if( $iline =~ /artist:\s+\b(.+?)$/ ){
$hsh{ artist } = $1;
}
if( $iline =~ /album:\s+\b(.+?)$/ ){
$hsh{ album } = $1;
}
}
my $newname = "$hsh{ artist }" . "-" . "$hsh{ album }" . "-" . "$hsh{ song }" . ".mp3";
$newname =~ s/\s+/_/g;
print "$_,$newname\n";
}
Monday, January 05, 2009
Autologging in and running app in X
I've been keen on doing this for some time, but a combination of:
- lack of need
- lack of time
Subscribe to:
Posts (Atom)