#!/usr/bin/perl -w

while(<STDIN>) {
	chomp;
	my $from = $_;
	my $to = $from;
	$to =~ s/%([0-9a-f][0-9a-f])/chr(hex($1))/gie;
	if ($from ne $to) {
		system "mv \"$from\" \"$to\"" || die "can't rename: $from -> $to: $!";
	}
}
