=head1	NAME

kls - Krause's ls clone

=head1	SYNOPSIS

kls I<options> I<file(s)>

=head1	DESCRIPTION

The kls program lists files and directories. The output column
order is configurable.

=head1	OPTIONS

=over 4

=item	B<-o> I<outputfile>

writes output to the specified file instead of writing to standard
output.

=item	B<-p> I<column-order>

specifies the order of output columns. Each character in the I<output-order>
string represents one of the following fields:

  n ... file name
  s ... file size in bytes
  t ... file type
  p ... permissions
  x ... message digest (see -m)
  l ... number of links
  c ... creation time stamp
  m ... modification time stamp
  a ... access time stamp
  u ... user ID
  g ... group ID
  d ... device number
  r ... relative device number
  i ... inode number

=item	B<-m> I<digest-type>

chooses a message digest type. The following digests can be used:

  MD5   ... RSA Data Security, Inc. MD5 Message-Digest
  SHA-1 ... SHA-1 message digest

=item	B<-r>

runs recursively (traverses all sub-directories).

=item	B<-t> I<file-types>

produces output only for the specified file types. Each character in
the I<file-types> string represents one file type:

  f ... regular files
  d ... directories
  p ... pipes
  c ... character special files
  b ... block special files
  s ... sockets
  o ... all types not named above.

=item	B<-l> I<symlink-depth>

restricts the number of symbolic links kls follows when traversing
directories recursively.

=item 	B<-d> I<directory-handling>

decides how to handle directories specified on the command line.
Use one of the following characters (or combine them):

  d ... give information about the directory itself
  c ... give information about the directory contents

=item	B<-f>

restricts recursive directory traversal to stay on the current
file system.

=item	B<-s>

shows a summary.

=item	B<-c> I<options>

configures the specified options as permanent options.

=item	B<-r> ...

ignores the permanent options.

=item	B<-u>

removes all permanent options.

=back

=head1	RETURN VALUE

The program returns exit code 0 on success, a positive value
on errors.

=head1	CAVEATS

The program lists file owners and groups only by ID, not by name.

=head1	SEE ALSO

http://dktools.sourceforge.net/kls.html

=head1	AUTHOR

Dirk Krause

=head1	COPYRIGHT AND LICENSE

Copyright (c) 2001-2008, Dirk Krause
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

 * Redistributions of source code must retain the above
   copyright notice, this list of conditions and the
   following disclaimer.

 * Redistributions in binary form must reproduce the above
   copyright notice, this list of conditions and the following
   disclaimer in the documentation and/or other materials
   provided with the distribution.

 * Neither the name of the Dirk Krause nor the names of
   contributors may be used to endorse or promote products
   derived from this software without specific prior written
   permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED.  IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

=head1	LAST MODIFICATION

2005/03/22

