summaryrefslogtreecommitdiffstats
path: root/usr.bin/du
Commit message (Collapse)AuthorAgeFilesLines
* New sentence, new line.joel2012-11-041-4/+4
| | | | Submitted by: brueffer
* Add a few basic examples.joel2012-11-041-1/+19
|
* Document -g option in the usage string.pluknet2012-07-261-1/+1
|
* Add -g (gigabyte) flag to complement -k (kilobyte) and -m (megabyte).des2012-07-182-7/+13
| | | | MFC after: 1 week
* du: Allow multiple -HLP options, the last one wins.jilles2011-12-172-20/+17
| | | | | | | This matches 4.4BSD tradition and other utilities with these options and is required by POSIX (POSIX does not specify -P, only -HL). MFC after: 2 weeks
* Update du(1):gjb2011-12-092-45/+53
| | | | | | | | | | | | | | - Sort arguments alphabetically where appropriate - '-B blocksize' is not mutually exclusive of '-h|-k|-m' - Mention '-t' in synopsis - Other wording improvements - Update usage() output to reflect the new synopsis [1] - Other miscellaneous improvements PR: 162438 Submitted by: arundel Reviewed by: Benjamin Kaduk (kaduk ! mit.edu), jhb[1] (original version) MFC after: 1 week
* Simplify getopt switch parsing.ed2011-11-081-12/+4
| | | | | | | | Only one of these flags can be set. Just add them together and check the value. Also, get rid of the listall variable. The code is already filled with direct *flag-comparisons. Obtained from: Alexander Best (though modified)
* Add missing static keywords to du(1)ed2011-11-061-1/+1
|
* Remove the advertising clause from UCB copyrighted files in usr.bin. Thisjoel2010-12-112-8/+0
| | | | | | | | | is in accordance with the information provided at ftp://ftp.cs.berkeley.edu/pub/4bsd/README.Impt.License.Change Also add $FreeBSD$ to a few files to keep svn happy. Discussed with: imp, rwatson
* Fix typos and spelling mistakes.joel2010-08-061-1/+1
|
* Add a -t switch for masking output that's above or below certain thresholds.brian2010-06-202-3/+28
| | | | | | | | | This switch makes it a lot easier to locate problem areas when a process is threatening to consume all of your disk space. PR: 144192 Submitted by: gk MFC after: 3 weeks
* Build usr.bin/ with WARNS=6 by default.ed2010-01-021-1/+0
| | | | Also add some missing $FreeBSD$ to keep svn happy.
* Report the next directory being scanned when a ^T is pressed (or anyimp2009-04-301-0/+15
| | | | | | | SIGINFO). Provides some progress report for the impatient. This won't report that we're blocking in our walk due to disk/network problems, however. There's no really good way to report that condition that I'm aware of...
* Restore (intmax_t) casts I lost during the last change & unbreak the build.mlaier2008-11-061-4/+6
|
* Add two new options to du(1):mlaier2008-11-062-35/+85
| | | | | | | | | | | | | | | | | | | | | | -A Display the apparent size instead of the disk usage. This can be helpful when operating on compressed volumes or sparse files. -B blocksize Calculate block counts in blocksize byte blocks. This is differ- ent from the -k, -m options or setting BLOCKSIZE and gives an estimate of how much space the examined file hierachy would require on a filesystem with the given blocksize. Unless in -A mode, blocksize is rounded up to the next multiple of 512. The former is similar to GNU's du(1) --apparent-size. The latter is different from what GNU's du(1) -B does, which is equivalent to setting BLOCKSIZE in our implementation and is rather pointless as it doesn't add any real value (i.e. you can achieve the same with a simple awk-script). No change in the normal output or processing. Reviewed by: keramida@, Peter French Otherwise silience from: freebsd-hackers@
* Declare functions and variables static and save a few byte. This is amlaier2008-11-041-9/+9
| | | | style(9)-change, too. Separate commit as it changes the object.
* style(9): mostly avoiding line wrap by not indenting cases. No obj change.mlaier2008-11-041-114/+121
|
* Implement from scratch a -l option for du(1), to match the same optionkeramida2008-02-252-11/+23
| | | | | | | | | | | | of the GNU utility. The default behavior of our original `du' is to count hardlinked files only once for each invocation of the utility. With the new -l option they count towards the final size every time they are found. PR: bin/117944 Submitted by: keramida Reviewed by: des, obrien MFC after: 2 weeks
* setenv(3) sets errno on failure, use warn() insteadkevlo2007-11-081-3/+3
| | | | Pointed out by: ru
* Check return value for setenv()kevlo2007-11-061-3/+7
|
* Significantly reduce the memory leak as noted in BUGS section forscf2007-07-041-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | setenv(3) by tracking the size of the memory allocated instead of using strlen() on the current value. Convert all calls to POSIX from historic BSD API: - unsetenv returns an int. - putenv takes a char * instead of const char *. - putenv no longer makes a copy of the input string. - errno is set appropriately for POSIX. Exceptions involve bad environ variable and internal initialization code. These both set errno to EFAULT. Several patches to base utilities to handle the POSIX changes from Andrey Chernov's previous commit. A few I re-wrote to use setenv() instead of putenv(). New regression module for tools/regression/environ to test these functions. It also can be used to test the performance. Bump __FreeBSD_version to 700050 due to API change. PR: kern/99826 Approved by: wes Approved by: re (kensmith)
* Back out all POSIXified *env() changes.ache2007-05-011-3/+3
| | | | | | | | | Not because I admit they are technically wrong and not because of bug reports (I receive nothing). But because I surprisingly meets so strong opposition and resistance so lost any desire to continue that. Anyone who interested in POSIX can dig out what changes and how through cvs diffs.
* Eliminate error with -W* strict flags and make putenv() calls conforming toache2007-04-301-3/+3
| | | | standard and portable in the same way as f.e. gcc internal portable code does.
* Markup fixes.ru2006-09-291-1/+5
|
* o Implement "-n" flag: ignore files and directories with user "nodump"maxim2006-05-062-3/+14
| | | | | | | | | flag set. Useful for calculation dump -h dump size. PR: bin/96864 Submitted by: Dmitry Kazarov Obtained from: NetBSD (man page) MFC after: 1 month
* Sync program's usage() with manpage's SYNOPSIS.ru2005-05-211-1/+1
|
* Remove unused variables.stefanf2005-04-091-2/+1
|
* Use 64bit 'fts_bignum' field instead of 32bit (on 32bit archs) fieldpjd2005-01-071-11/+13
| | | | | | | | | | | | 'fts_number' to remember number of blocks. This makes du(1) 64bit-clean. This work is part of the BigDisk project: http://www.FreeBSD.org/projects/bigdisk/ Discussed on: arch@ MFC after: 5 days
* Add a missing full-stop to match the rest of the items in a list.keramida2004-10-241-1/+1
|
* Use the length modifier 'll' instead of 'q' to print long longs.stefanf2004-07-281-1/+1
|
* Respect locale settings from the environment.tjr2004-07-151-0/+3
|
* Mechanically kill hard sentence breaks.ru2004-07-021-2/+4
|
* typos.phk2004-06-021-2/+2
| | | | Pointed out by: ru
* Give du(1) a -m option to report in megabytes.phk2004-06-022-10/+9
| | | | | Submitted by: Vasily Korytov <deskpot@msk.yell.ru> PR: 66976
* Use humanize_number(3) to format sizes into a human readable form.pjd2004-05-242-69/+11
|
* Mark du(1) as WARNS6 clean.pjd2004-05-241-0/+1
| | | | Tested on: alpha, amd64, i386, ia64, sparc64
* More style fixes, per bde.kientzle2004-05-021-6/+4
|
* Style fixes, most suggested by bde.kientzle2004-05-011-24/+19
|
* Speed up hardlink detection by using a self-sizing hashkientzle2004-04-301-32/+141
| | | | | | | | | | | | | | table rather than the old linear list search. On my "hardlink detection torture test", this reduced user time from 4700 seconds down to 4.2 seconds and wallclock time from 1:24:48 down to 1:08. (Yes, that's over one THOUSAND times reduction in user time. ;-) In the worst case, the new code doubles peak memory usage, though it could actually reduce memory usage in many cases. MFC after: 1 week PR: misc/42167, bin/51151
* -{h,k} are mutually exclisive. So only pay attention to the last of theobrien2003-03-301-2/+2
| | | | two when both are given.
* Back out rev 1.27; getbsize(3)'s original interface has been restored.mike2002-12-301-2/+1
| | | | Approved by: markm
* Uniformly refer to a file system as "file system".ru2002-12-121-2/+2
| | | | Approved by: re
* Change the type of an unused variable to appease a warning.markm2002-10-231-1/+2
|
* ANSIify function definitions to avoid a warning.dwmalone2002-07-281-15/+8
|
* Consistently use FBSDIDobrien2002-06-301-3/+2
|
* More consistancy. file system > filesystemtrhodes2002-05-161-1/+1
|
* Use `The .Nm utility'charnier2002-04-191-2/+3
|
* remove __Pimp2002-03-221-7/+7
|
* Remove leaf node WARNS?=2 (that mainly I added). This shouldmarkm2002-02-081-1/+0
| | | | help the GCC3 transition and CURRENT in general.
* GRR. This was not WARNS=2 clean. You cannot printf a 'long' withpeter2002-02-081-1/+1
| | | | | | | | '%qd'. usr.bin/du/du.c:288: warning: long long int format, long int arg (arg 2) Pointy hat to: markm
OpenPOWER on IntegriCloud