#!/usr/local/bin/perl #@(#) hexdump.pl - Dump file in Hex format use strict; # Perl pragma to restrict unsafe constructs use diagnostics; # produce verbose warning diagnostics use warnings; # Perl pragma to control optional warnings use Data::HexDump; print STDERR "$0 HexDump\n"; if ( 0 > $#ARGV) { print STDERR "Usage: $0 <file>\n"; exit; } for (@ARGV) { print STDERR "Dumping [$_]\n"; my $f = new Data::HexDump; $f->file($_); $f->block_size(1024); print while $_ = $f->dump; } __END__