in reply to Removing Duplicate Lines from a File
This should only print each line in my_file.txt once:
perl -ne 'print unless $n{$_}++' my_file.txt
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Removing Duplicate Lines from a File
by johnirl (Monk) on Jul 17, 2002 at 15:35 UTC | |
by jeffa (Bishop) on Jul 17, 2002 at 15:44 UTC | |
by broquaint (Abbot) on Jul 17, 2002 at 15:44 UTC |