


UNIQ(1L)                                                 UNIQ(1L)


NNAAMMEE
       uniq - remove duplicate lines from a sorted file

SSYYNNOOPPSSIISS
       uunniiqq  [-cdu]  [-f  skip-fields] [-s skip-chars] [-w check-
       chars]    [-#skip-fields]     [+#skip-chars]     [--count]
       [--repeated]     [--unique]    [--skip-fields=skip-fields]
       [--skip-chars=skip-chars]      [--check-chars=check-chars]
       [--help] [--version] [infile] [outfile]

DDEESSCCRRIIPPTTIIOONN
       This  manual page documents the GNU version of uunniiqq.  uunniiqq
       prints the unique lines in a sorted file,  discarding  all
       but  one  of  a  run of matching lines.  It can optionally
       show only lines that appear exactly once,  or  lines  that
       appear more than once.  uunniiqq requires sorted input because
       it compares only consecutive lines.

       If the output file is not specified, uunniiqq  writes  to  the
       standard  output.   If the input file is not specified, it
       reads from the standard input.

   OOPPTTIIOONNSS
       _-_u_, _-_-_u_n_i_q_u_e
              Only print unique lines.

       _-_d_, _-_-_r_e_p_e_a_t_e_d
              Only print duplicate lines.

       _-_c_, _-_-_c_o_u_n_t
              Print the number of times each line occurred  along
              with the line.

       _-_n_u_m_b_e_r_, _-_f_, _-_-_s_k_i_p_-_f_i_e_l_d_s_=_n_u_m_b_e_r
              In  this  option, _n_u_m_b_e_r is an integer representing
              the number of fields to skip over  before  checking
              for  uniqueness.   The  first  _n_u_m_b_e_r fields, along
              with any  blanks  found  before  _n_u_m_b_e_r  fields  is
              reached,  are skipped over and not counted.  Fields
              are defined as  a  strings  of  non-space,  non-tab
              characters,  that  are separated from each other by
              spaces and tabs.

       _+_n_u_m_b_e_r_, _-_s_, _-_-_s_k_i_p_-_c_h_a_r_s_=_n_u_m_b_e_r
              In this option, _n_u_m_b_e_r is an  integer  representing
              the number of characters to skip over before check-
              ing for uniqueness.  The first  _n_u_m_b_e_r  characters,
              along  with  any blanks found before _n_u_m_b_e_r charac-
              ters is reached, are skipped over and not  counted.
              If  you  use  both the field and character skipping
              options, fields are skipped over first.

       _-_w_, _-_-_c_h_e_c_k_-_c_h_a_r_s_=_n_u_m_b_e_r
              Specify the number of characters to compare in  the



FSF                     GNU Text Utilities                      1





UNIQ(1L)                                                 UNIQ(1L)


              lines,  after  skipping  any  specified  fields and
              characters.  Normally the entire rest of the  lines
              are compared.

       _-_-_h_e_l_p Print a usage message and exit with a non-zero sta-
              tus.

       _-_-_v_e_r_s_i_o_n
              Print version information on standard  output  then
              exit.















































FSF                     GNU Text Utilities                      2


