#!/usr/local/bin/perl -i~

# Loop over all lines looking for duplicate entries and just retaining
# the first one

LINE: while (<>) {
    if (/^\s*(\S+)/) {
	# See if this entry is already present
	next LINE if ($included{$1});
	$included{$1} = 1;
    }
    print;
}
