Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ uniq(1) — UnixWare 2.01

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

comm(1)

sort(1)






       uniq(1)                                                      uniq(1)


       NAME
             uniq - report repeated lines in a file

       SYNOPSIS
             uniq [-ffields] [-schars] [-cdu] [input [output]]
             uniq [+n] [-n] [-cdu] [input [output]]

       DESCRIPTION
             uniq reads the input file and compares adjacent lines.  By
             default, the second and succeeding copies of repeated lines
             are removed; the remainder is written on the output file;
             input and output should always be different.  Note that
             repeated lines must be adjacent in order to be found; see
             sort(1).

             uniq processes supplementary code set characters according to
             the locale specified in the LC_CTYPE environment variable [see
             LANG on environ(5)].

             uniq takes the following options:

             -u          Output only the lines that are not repeated in the
                         original file.

             -d          Output one copy of just the repeated lines.  The
                         default output is the union of the -u and -d
                         outputs.

             -c          Generate the default output but with each line
                         preceded by a count of the number of times it
                         occurred.  The -c option supersedes -u and -d.

             The following options specify skipping an initial portion of
             each line in the comparison:

             -ffields    Ignore the first fields fields together with any
                         blanks before each field.  A field is defined as a
                         string of non-space, non-tab characters separated
                         by tabs and spaces from its neighbors. If fields
                         specifies a field that is not present in the input
                         line, it is treated as a null string.

             -schars     Ignore the first chars characters.  Fields are
                         skipped before characters. If chars specifies more
                         characters than are on the input line, the missing
                         characters are treated as a null string.


                           Copyright 1994 Novell, Inc.               Page 1













      uniq(1)                                                      uniq(1)


            +n          (Obsolescent.) Same as ``-s n''.

            -n          (Obsolescent.) Same as ``-f n''.

      FILES
            /usr/lib/locale/locale/LC_MESSAGES/uxdfm
                  language-specific message file [See LANG on environ(5).]

      REFERENCES
            comm(1), sort(1)

      NOTICES
            +n and -n may not be supported in future releases.  Their use
            is discouraged.


































                          Copyright 1994 Novell, Inc.               Page 2








Typewritten Software • bear@typewritten.org • Edmonds, WA 98026