Gimme my `-k' option back!
This commit is contained in:
parent
670a01d488
commit
4133bd443a
@ -67,6 +67,11 @@ All symbolic links are followed.
|
|||||||
No symbolic links are followed.
|
No symbolic links are followed.
|
||||||
.It Fl a
|
.It Fl a
|
||||||
Display an entry for each file in the file hierarchy.
|
Display an entry for each file in the file hierarchy.
|
||||||
|
.It Fl k
|
||||||
|
Report in 1024-byte (1-Kbyte) blocks rather than the default. Note that
|
||||||
|
this overrides the
|
||||||
|
.Ev BLOCKSIZE
|
||||||
|
setting from the environment.
|
||||||
.It Fl s
|
.It Fl s
|
||||||
Display only the grand total for the specified files.
|
Display only the grand total for the specified files.
|
||||||
.It Fl x
|
.It Fl x
|
||||||
|
@ -73,7 +73,7 @@ main(argc, argv)
|
|||||||
save = argv;
|
save = argv;
|
||||||
Hflag = Lflag = Pflag = aflag = sflag = 0;
|
Hflag = Lflag = Pflag = aflag = sflag = 0;
|
||||||
ftsoptions = FTS_PHYSICAL;
|
ftsoptions = FTS_PHYSICAL;
|
||||||
while ((ch = getopt(argc, argv, "HLPasx")) != EOF)
|
while ((ch = getopt(argc, argv, "HLPaksx")) != EOF)
|
||||||
switch (ch) {
|
switch (ch) {
|
||||||
case 'H':
|
case 'H':
|
||||||
Hflag = 1;
|
Hflag = 1;
|
||||||
@ -90,6 +90,9 @@ main(argc, argv)
|
|||||||
case 'a':
|
case 'a':
|
||||||
aflag = 1;
|
aflag = 1;
|
||||||
break;
|
break;
|
||||||
|
case 'k':
|
||||||
|
putenv("BLOCKSIZE=1024");
|
||||||
|
break;
|
||||||
case 's':
|
case 's':
|
||||||
sflag = 1;
|
sflag = 1;
|
||||||
break;
|
break;
|
||||||
@ -224,6 +227,6 @@ usage()
|
|||||||
{
|
{
|
||||||
|
|
||||||
(void)fprintf(stderr,
|
(void)fprintf(stderr,
|
||||||
"usage: du [-H | -L | -P] [-a | -s] [-x] [file ...]\n");
|
"usage: du [-H | -L | -P] [-a | -s] [-k] [-x] [file ...]\n");
|
||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user