summaryrefslogtreecommitdiffstats
path: root/bin/ls/util.c
Commit message (Collapse)AuthorAgeFilesLines
* - Add -D to usage().ru2008-04-041-2/+2
| | | | | - Bump document date for the addition of the -D option. - Reformat a sentence to look like a real sentence.
* Add a new -U flag to instruct ls to use the birthtime for printing orjhb2006-03-241-2/+2
| | | | | | | sorting. Submitted by: Andrzej Tobola ato at iem dot pw dot edu dot pl MFC after: 1 week
* Having three options (-a, -A, -I) controlling the output of dottedru2005-11-161-2/+2
| | | | | | | | | | | files is too much and hard to follow. Instead, make the -I option just mean "do not automatically set -A for root". That is, if -A is explicitly set, -I is ignored. Also, document -I in usage(). (The ls.c diff is better viewed relative to rev. 1.80.) No objection: mux Silence from: mnag MFC after: 3 days
* Add the -S option to sort files by size. NetBSD and OpenBSD alreadydd2005-06-031-2/+2
| | | | | | | | have this option with identical semantics (sorting large files first). -r can be used to reverse the sort if that is desired. PR: 81625 Submitted by: Kostas Blekos <mplekos@physics.upatras.gr>, keramida
* Sync program's usage() with manpage's SYNOPSIS.ru2005-02-091-2/+2
|
* /*- or .\"- or #- to begin license clauses.imp2005-01-101-1/+1
|
* Only add the widths together for printable characters in prn_normal();tjr2004-05-031-1/+2
| | | | unprintable characters have a "width" of -1.
* Treat filenames as multibyte character strings (according to the currenttjr2004-05-021-59/+128
| | | | | | | | | | | | | LC_CTYPE setting) when determining which characters are printable. This is an often-requested feature. Use wcwidth() to determine the number of column positions a character takes up, although there are still a few places left where we assume 1 byte = 1 column position, e.g. line-wrapping when handling the -m option. The error handling here is somewhat more complicated than usual: we do our best to show what we can of a filename in the presence of conversion errors, instead of simply aborting.
* Remove clause 3 from the UCB licenses.markm2004-04-061-4/+0
| | | | OK'ed by: imp, core
* Add the -m, -w and -x options to ls's usage message.tjr2003-09-091-2/+2
| | | | | | PR: 51493 Submitted by: Walter Belgers MFC after: 1 month
* Fix a bazillion warnings. This makes almost the whole of src/bin/*markm2003-05-031-1/+1
| | | | | | WARNS=6, std=c99 clean. Tested on: i386, alpha
* Consistently use __FBSDIDobrien2002-06-301-4/+2
|
* Add (unsigned char) cast lost in WARNS=4 fixes which break 8bit localesache2002-02-281-1/+1
| | | | PR: 35421
* Use __FBSDID() and clean up the vendor tags.markm2002-02-031-5/+6
|
* WARNS=4 fixes, plus a healthy dose of fixes inspired by lint.markm2002-02-031-6/+5
|
* o __P has been reovedimp2002-02-021-8/+4
| | | | | | | | | o Old-style K&R declarations have been converted to new C89 style o register has been removed o prototype for main() has been removed (gcc3 makes it an error) o int main(int argc, char *argv[]) is the preferred main definition. o Attempt to not break style(9) conformance for declarations more than they already are.
* Add a new flag, -h which when combined with the -l option causesjoe2001-12-281-2/+2
| | | | | | | | file sizes to be displayed with unit suffixes; Byte, Kilobyte, Megabyte, Gigabyte, Terabyte and Petabyte in order to reduce the number of digits to three or less. Submitted by: nik
* Add LOMAC options (the "Z" flag in both cases) to display extra informationgreen2001-11-261-2/+2
| | | | | | in ls(1) and ps(1). Sponsored by: DARPA, NAI Labs
* Add the missing flags to ls(1)'s usage: -Bb.green2000-07-221-2/+2
|
* make sure we do not write out non-printable characters in file namesassar2000-07-041-11/+13
| | | | | | | and symbolic links (by default) PR: bin/19354 Reviewed by: silence on -current
* Add -G to usage: if COLORLSache2000-06-061-1/+6
|
* $Id$ -> $FreeBSD$peter1999-08-271-1/+1
|
* Add -n option to print numeric user and group IDs instead of namessheldonh1999-08-021-2/+2
| | | | | | | | | | | | 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
* Doh. What was I smoking when I wrote this?des1998-10-131-5/+5
| | | | | PR: bin/8301 Submitted by: Tetsuya Furukawa <tetsuya@secom-sis.co.jp>
* Fix nasty error in len_octal, result not initializedache1998-04-251-2/+2
|
* Fix ctype error #1 - chars must be unsignedache1998-04-251-2/+2
|
* Remove the bogus -? option after reading the getopt() manual :)des1998-04-241-2/+2
|
* o Removed two unused variables (f_dirname and f_newline) in ls.cdes1998-04-241-16/+5
| | | | | | | | | | | | | | | 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
* o Renamed '-b' (show unprintables in octal) to '-B'des1998-04-241-10/+66
| | | | | | | | 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.
* Added -b option to display unprintables in octal.des1998-04-211-1/+40
| | | | PR: 1315
* Observe precedence set by Phillippe Charnier in adding ansteve1997-08-071-3/+5
| | | | rcsid.
* Remove #if(n)def BSD_4_4_LITE cruft and sccsid -> rcsid.steve1997-08-071-2/+3
|
* make usage() and SYNOPSIS agree with each other and add missing optionsobrien1997-03-261-2/+2
| | | | documented in the DESCRIPTION section.
* Revert $FreeBSD$ to $Id$peter1997-02-221-1/+1
|
* Make the long-awaited change from $Id$ to $FreeBSD$jkh1997-01-141-1/+1
| | | | | | | | 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.
* Merge Lite2 mods, and -Wall cleaning. undelete(2) cruftsteve1996-12-141-2/+6
| | | | | | not yet implemented is protected by a define (BSD4_4_LITE) that should be removed when this call is supported by the kernel.
* Use unsigned char for isprintache1996-03-311-2/+2
|
* Back out ctype fix, unneded with new ctypeache1994-10-091-2/+2
|
* Added $Id$dg1994-09-241-0/+2
|
* Make ls ctype-awareache1994-09-211-1/+1
|
* BSD 4.4 Lite bin Sourcesrgrimes1994-05-261-0/+71
OpenPOWER on IntegriCloud