On 12/24/19 9:21 AM, Robert Elz wrote: > The -u option appaeared in 7th edition Bell Labs Unix (1979) [I would > assume it was actually implemented somewhat earlier, that's when 7th > edition was released to the rest of the world.]
Thanks, the POSIX 2004 manual is just the earliest standard I can easily track down (via pubs.opengroup.org) so I know it's "at least" that old. :D > Also note that sort -u and sort | uniq are not quite the same, the -u > option only considers the key fields when deciding which records (lines) > are unique (of course, with no key options, the whole line is the key, > in which case they are more or less the same). Hmm, is that "more or less" the same, or actually the same? Seems like it would be actually the same... in which case I'd rephrase it to say "sort -u can do things that uniq can't, because it takes an optional key modifier". (uniq does have -s / -f which is sort of kind of partially approaching the same thing, but eh, doesn't really count.) -- Eli Schwartz Arch Linux Bug Wrangler and Trusted User
signature.asc
Description: OpenPGP digital signature