#!/usr/bin/perl -w
#
# Joshua D. Abraham (jabra@spl0it.org)
# Mon Oct 20 19:44:11 EDT 2008
#
# unpackage a debian package to the current directory
#
use strict;
if ( defined($ARGV[0]) ) {
    my $dir = uc($ARGV[0]);
    my $file = $ARGV[0];
    $dir =~ s/\.deb//ig;
    system("dpkg-deb -x $file $dir");
    system("dpkg-deb -e $file $dir/DEBIAN");
}
else {
    print "$0 [file.deb]\n";
}
