UNIQ(1plan9)
π UNIQ(1plan9) π
okay bestie, welcome to uniq β it's the plan9 girlie whose whole personality is reporting repeated lines in a file. she's giving quiet luxury, she's giving deduplication, and she is so easy to love once you get her β¨
πΈ SYNOPSIS πΈ
uniq [ -udc [ +-num ] ] [ file ]
π¦ DESCRIPTION π¦
So here's the vibe: uniq copies the input file, or the standard input if you didn't hand her a file, and drops it straight onto the standard output β comparing adjacent lines as she goes. π
In the normal case (no flags, just vibing), the second and succeeding copies of repeated lines get removed. like, bye π one copy stays, the clones are gone.
β οΈ real talk though: repeated lines must be adjacent in order to be found. she is NOT scanning the whole file for you. if your dupes are scattered, that's not her problem, bestie β that's a sort(1) problem. π
β¨ OPTIONS β¨
-uβ print unique lines. just the ones that show up once. main character only π-dβ print (one copy of) duplicated lines. the repeats get to stay, but only one of them, no group-chat spam.-cβ prefix a repetition count and a tab to each output line. and yes, she's dramatic: this implies-uand-d. both. at once. she contains multitudes π-numβ the first num fields, together with any blanks before each, get ignored. a field is defined as a string of non-space, non-tab characters separated by tabs and spaces from its neighbors. so like, skip the first num fields, blanks included, no cap π+numβ the first num characters get ignored. and the tea here: fields are skipped before characters. order matters, iykyk π§
π SOURCE π
/src/cmd/uniq.c
π SEE ALSO π
sort(1)β the other half of this situationship fr fr π«Ά
π BUGS π
field selection and comparison should be compatible with sort(1). that's it, that's the bug note. she said "it should be" and left it at that π
and that's the whole page, bestie!! this lil icon lives in the plan9 manual as UNIQ(1plan9) β you can catch her under UNIQ(1plan9), and no date on the footer, so she's just timeless like that βπ slay, go dedupe something, periodt β¨
π¦ where this page comes from
- debian bookworm: 9base 1:6-13 Β· Lucent
- debian trixie: 9base 1:6-14 Β· Lucent
- ubuntu jammy: 9base 1:6-11 Β· Lucent
- ubuntu noble: 9base 1:6-14 Β· Lucent
- ubuntu questing: 9base 1:6-15
- ubuntu resolute: 9base 1:6-15build1 Β· Lucent
- ubuntu stonking: 9base 1:6-15build1 Β· Lucent
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms