Commit Graph

30 Commits

Author SHA1 Message Date
peter
66312e4a8d $Id$ -> $FreeBSD$ 1999-08-27 23:15:48 +00:00
chris
f92dd3f904 Backed out my -n change to imply -l by request of sheldonh. 1999-08-23 05:39:40 +00:00
chris
4a1cbe0182 Make -n flag compliant to the Single Unix Specification.
To quote their ls(1) specification:

   -n
          The same as -l, except that the owner's UID and GID numbers are
          written, rather than the associated character strings.

Reviewed by:	green
1999-08-23 01:17:58 +00:00
sheldonh
7c5ab4e28d Take integer rounding into account in the buffer size approximation
macro. So now it's (1 +) for the sign and (+ 1) for rounding.

Reported by:	bde
1999-08-19 13:04:08 +00:00
sheldonh
c57b7dbc2a Style issues in previous commit:
Use an upward approximation of the number of characters required
        for decimal representations of uid_t, gid_t and u_quad_t, intead
	of arbitrary values that may not be safe in the future.

	Fix disordering.

Requested by:	bde
1999-08-19 11:36:12 +00:00
sheldonh
744826805a Add -n option to print numeric user and group IDs instead of names
in a long (-l) listing.

MFC-jockies should make sure that bde's concerns regarding the number
of digits required to represent a uid_t and the use of snprintf
on the associated PR have been addressed before going wild.

PR:	12866
Reported by:	Philip Kizer <pckizer@nostrum.com>
Obtained from:	NetBSD
1999-08-02 14:55:58 +00:00
kris
713dd62834 Various spelling/formatting changes.
Submitted by: Philippe Charnier <charnier@xp11.frmug.org>
1999-05-08 10:22:15 +00:00
hoek
62b257a6d9 Add missing "else", without whom the prev. commit is a null change.
Fix a 2nd level indentation style bug.
1998-08-02 22:47:11 +00:00
hoek
eb80fc954a Allow env. variable LS_COLWIDTHS to specify minimum column widths,
effectively overriding the dynamically-sized-column feature.  This
is mostly useful for non-interactive use, where it may be necessary
to ensure that listings taken at different times have columns that
line-up correctly.  I have been assured that at least one large,
well-known program will soon be taking advantage of this.  :-)

PR:		bin/7011
Submitted by:	Joel Ray Holveck <joelh@gnu.org>
1998-07-29 00:46:13 +00:00
des
fc8308de88 Remove the bogus -? option after reading the getopt() manual :) 1998-04-24 20:15:43 +00:00
des
7f8983e5f5 o Removed two unused variables (f_dirname and f_newline) in ls.c
o Added the -H and -P options for treatment of symbolic links.

o Removed the #ifdef BSD4_4_LITE, since it does not seem to do anything
  useful

o Fixed up prn_octal() so its output looks more like that of AT&T Unices
  when -b is given.

The next two lines apply only to the first two changes above:

PR:		bin/6140
Submitted by:	Max Euston
1998-04-24 12:43:26 +00:00
des
aedfea1af8 o Renamed '-b' (show unprintables in octal) to '-B'
o Added a new '-b' which behaves as in AT&T Unices (show unprintables in
  octal, using C escape codes when possible)

o Added '?' to the getopt() string, since the code in the switch considers
  it as a valid option.
1998-04-24 07:49:51 +00:00
des
88ece5135a Added -b option to display unprintables in octal.
PR: 1315
1998-04-21 22:02:01 +00:00
sef
2e215bb009 Fix sorting of directories when doing '-d'.
PR:		bin/4558
Submitted by:	Keith Bostic
1997-09-18 06:42:27 +00:00
steve
34c71a268a Observe precedence set by Phillippe Charnier in adding an
rcsid.
1997-08-07 22:28:25 +00:00
steve
2eae399bf6 Remove #if(n)def BSD_4_4_LITE cruft and sccsid -> rcsid. 1997-08-07 15:33:50 +00:00
imp
054f35c222 compare return value from getopt against -1 rather than EOF, per the final
posix standard on the topic.
1997-03-28 15:24:41 +00:00
peter
83b3c2c161 Revert $FreeBSD$ to $Id$ 1997-02-22 14:13:04 +00:00
jkh
808a36ef65 Make the long-awaited change from $Id$ to $FreeBSD$
This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.

Boy, I'm glad we're not using sup anymore.  This update would have been
insane otherwise.
1997-01-14 07:20:47 +00:00
steve
69ca26a305 Merge Lite2 mods, and -Wall cleaning. undelete(2) cruft
not yet implemented is protected by a define (BSD4_4_LITE)
that should be removed when this call is supported by the
kernel.
1996-12-14 06:03:29 +00:00
adam
b3dbeb6c53 set error status on exit, to be consistent with manpage and standard commands. 1996-08-27 21:51:48 +00:00
ache
31de4a4cc9 Change locale to LC_ALL, there no bitmask 1995-10-26 10:56:38 +00:00
ache
76a4f2bbdd Change LC_ALL to LC_CTYPE|LC_TIME - small optimization 1995-10-23 21:09:01 +00:00
ache
80200799c7 Add setlocale LC_ALL 1995-10-23 20:36:26 +00:00
phk
d42111863a Having BLOCKSIZE=K and using "-k" option ls would use 2K block size... 1995-03-23 19:05:00 +00:00
joerg
c6030c6511 You will find enclosed some changes to make gcc -Wall more happy in
/usr/src/bin. Note that some patches are still needed in that directory.

I (Joerg) finished most of Philippe's cleanup.  /bin/sh will still
need *allot* of work, however.

Submitted by:	charnier@lirmm.fr (Philippe Charnier)
1995-03-19 13:29:28 +00:00
joerg
30a0fe9c66 Make ls recognize the COLUMNS environmental variable, even
in cases where it does not run on a terminal.  This is important
e.g. for commands like

	env COLUMNS=132 ls -CR | lpr -Psome-wide-printer
1994-12-18 19:00:01 +00:00
dg
8722740e7f Added $Id$ 1994-09-24 02:59:15 +00:00
pst
7963d9a803 Add support for '-k' option to print file allocation space in 'K' instead of
system blocks.

This is semi-original code, not the same way this crufty option was handled
in FreeBSD 1.x.
1994-09-19 07:49:56 +00:00
rgrimes
e3cfc8ce61 BSD 4.4 Lite bin Sources 1994-05-26 06:18:55 +00:00