#!/usr/bin/perl

opendir(DIR, '.');
foreach $file (readdir(DIR)) {
    next if !($file =~ /\.img$/);
    $newfile = $file;
    $newfile =~ s/img/bin/;
    system "mv $file $newfile";
}
