bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#13032: 24.3.50; Request: Provide a `delete-duplicate-lines' command


From: Juri Linkov
Subject: bug#13032: 24.3.50; Request: Provide a `delete-duplicate-lines' command
Date: Fri, 30 Nov 2012 03:12:05 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (x86_64-pc-linux-gnu)

>>   C-u M-| awk -- '!a[$0]++' RET
>
> Isn't
>
>   C-u M-| uniq RET
>
> shorter and easier to type?

I use `uniq' only on files where lines are sorted.  OTOH, something like
'!a[$0]++' that is not limited to consecutive duplicates is better for
files where lines are not sorted such as log files, etc.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]