More Doc updates. cmdedit and more termio fixes.

This commit is contained in:
Erik Andersen
2000-04-21 01:26:49 +00:00
parent cf8d38a3eb
commit 1d1d95051a
35 changed files with 278 additions and 133 deletions

View File

@@ -29,7 +29,11 @@ extern int basename_main(int argc, char **argv)
char* s, *s1;
if ((argc < 2) || (**(argv + 1) == '-')) {
usage("basename [file ...]\n");
usage("basename [FILE ...]\n"
#ifndef BB_FEATURE_TRIVIAL_HELP
"\nStrips directory path and suffixes from FILE(s).\n"
#endif
);
}
argv++;

View File

@@ -45,7 +45,11 @@ extern int cat_main(int argc, char **argv)
}
if (**(argv + 1) == '-') {
usage("cat [file ...]\n");
usage("cat [FILE ...]\n"
#ifndef BB_FEATURE_TRIVIAL_HELP
"\nConcatenates FILE(s) and prints them to the standard output.\n"
#endif
);
}
argc--;

View File

@@ -28,9 +28,11 @@
#include <errno.h>
static const char chroot_usage[] = "chroot NEWROOT [COMMAND...]\n\n"
"Run COMMAND with root directory set to NEWROOT.\n";
static const char chroot_usage[] = "chroot NEWROOT [COMMAND...]\n"
#ifndef BB_FEATURE_TRIVIAL_HELP
"\nRun COMMAND with root directory set to NEWROOT.\n"
#endif
;

View File

@@ -40,12 +40,14 @@
mail commands */
static const char date_usage[] = "date [OPTION]... [+FORMAT]\n"
" or: date [OPTION] [MMDDhhmm[[CC]YY][.ss]]\n\n"
"Display the current time in the given FORMAT, or set the system date.\n"
"\nOptions:\n\t-R\t\toutput RFC-822 compliant date string\n"
"\t-s\t\tset time described by STRING\n"
"\t-u\t\tprint or set Coordinated Universal Time\n";
" or: date [OPTION] [MMDDhhmm[[CC]YY][.ss]]\n"
#ifndef BB_FEATURE_TRIVIAL_HELP
"\nDisplays the current time in the given FORMAT, or sets the system date.\n"
"\nOptions:\n\t-R\tOutputs RFC-822 compliant date string\n"
"\t-s\tSets time described by STRING\n"
"\t-u\tPrints or sets Coordinated Universal Time\n"
#endif
;
/* Input parsing code is always bulky - used heavy duty libc stuff as

View File

@@ -9,6 +9,6 @@ extern int length_main(int argc, char **argv)
if (argc != 2 || **(argv + 1) == '-') {
usage("length string\n");
}
printf("%d\n", strlen(argv[1]));
printf("%lu\n", (long)strlen(argv[1]));
return (TRUE);
}