diff options
Diffstat (limited to 'coreutils')
-rw-r--r-- | coreutils/chroot.c | 2 | ||||
-rw-r--r-- | coreutils/cp.c | 2 | ||||
-rw-r--r-- | coreutils/date.c | 2 | ||||
-rw-r--r-- | coreutils/dd.c | 5 | ||||
-rw-r--r-- | coreutils/ln.c | 6 | ||||
-rw-r--r-- | coreutils/mkdir.c | 7 | ||||
-rw-r--r-- | coreutils/mknod.c | 6 | ||||
-rw-r--r-- | coreutils/mv.c | 2 | ||||
-rw-r--r-- | coreutils/rm.c | 3 | ||||
-rw-r--r-- | coreutils/rmdir.c | 2 | ||||
-rw-r--r-- | coreutils/sleep.c | 4 | ||||
-rw-r--r-- | coreutils/sync.c | 2 | ||||
-rw-r--r-- | coreutils/touch.c | 4 | ||||
-rw-r--r-- | coreutils/uname.c | 5 |
14 files changed, 27 insertions, 25 deletions
diff --git a/coreutils/chroot.c b/coreutils/chroot.c index 8e432b36c..16524d92e 100644 --- a/coreutils/chroot.c +++ b/coreutils/chroot.c | |||
@@ -27,7 +27,7 @@ | |||
27 | #include <errno.h> | 27 | #include <errno.h> |
28 | 28 | ||
29 | 29 | ||
30 | static const char chroot_usage[] = "NEWROOT [COMMAND...]\n" | 30 | static const char chroot_usage[] = "chroot NEWROOT [COMMAND...]\n\n" |
31 | "Run COMMAND with root directory set to NEWROOT.\n"; | 31 | "Run COMMAND with root directory set to NEWROOT.\n"; |
32 | 32 | ||
33 | 33 | ||
diff --git a/coreutils/cp.c b/coreutils/cp.c index 9dac2afbc..57158c820 100644 --- a/coreutils/cp.c +++ b/coreutils/cp.c | |||
@@ -28,7 +28,7 @@ | |||
28 | #include <dirent.h> | 28 | #include <dirent.h> |
29 | 29 | ||
30 | static const char cp_usage[] = "cp [OPTION]... SOURCE DEST\n" | 30 | static const char cp_usage[] = "cp [OPTION]... SOURCE DEST\n" |
31 | " or: cp [OPTION]... SOURCE... DIRECTORY\n" | 31 | " or: cp [OPTION]... SOURCE... DIRECTORY\n\n" |
32 | "Copy SOURCE to DEST, or multiple SOURCE(s) to DIRECTORY.\n" | 32 | "Copy SOURCE to DEST, or multiple SOURCE(s) to DIRECTORY.\n" |
33 | "\n" | 33 | "\n" |
34 | "\t-a\tsame as -dpR\n" | 34 | "\t-a\tsame as -dpR\n" |
diff --git a/coreutils/date.c b/coreutils/date.c index 501ccc28f..6be89df3e 100644 --- a/coreutils/date.c +++ b/coreutils/date.c | |||
@@ -35,7 +35,7 @@ | |||
35 | mail commands */ | 35 | mail commands */ |
36 | 36 | ||
37 | static const char date_usage[] = "date [OPTION]... [+FORMAT]\n" | 37 | static const char date_usage[] = "date [OPTION]... [+FORMAT]\n" |
38 | " or: date [OPTION] [MMDDhhmm[[CC]YY][.ss]]\n" | 38 | " or: date [OPTION] [MMDDhhmm[[CC]YY][.ss]]\n\n" |
39 | "Display the current time in the given FORMAT, or set the system date.\n" | 39 | "Display the current time in the given FORMAT, or set the system date.\n" |
40 | "\nOptions:\n\t-R\t\toutput RFC-822 compliant date string\n" | 40 | "\nOptions:\n\t-R\t\toutput RFC-822 compliant date string\n" |
41 | "\t-s\t\tset time described by STRING\n" | 41 | "\t-s\t\tset time described by STRING\n" |
diff --git a/coreutils/dd.c b/coreutils/dd.c index 33c45940e..800ed59f8 100644 --- a/coreutils/dd.c +++ b/coreutils/dd.c | |||
@@ -34,7 +34,7 @@ | |||
34 | #include <errno.h> | 34 | #include <errno.h> |
35 | 35 | ||
36 | static const char dd_usage[] = | 36 | static const char dd_usage[] = |
37 | "dd [if=name] [of=name] [bs=n] [count=n]\n" | 37 | "dd [if=name] [of=name] [bs=n] [count=n]\n\n" |
38 | "Copy a file, converting and formatting according to options\n\n" | 38 | "Copy a file, converting and formatting according to options\n\n" |
39 | "\tif=FILE\tread from FILE instead of stdin\n" | 39 | "\tif=FILE\tread from FILE instead of stdin\n" |
40 | "\tof=FILE\twrite to FILE instead of stout\n" | 40 | "\tof=FILE\twrite to FILE instead of stout\n" |
@@ -227,8 +227,7 @@ extern int dd_main (int argc, char **argv) | |||
227 | exit( TRUE); | 227 | exit( TRUE); |
228 | usage: | 228 | usage: |
229 | 229 | ||
230 | fprintf (stderr, "%s", dd_usage); | 230 | usage( dd_usage); |
231 | exit( FALSE); | ||
232 | } | 231 | } |
233 | 232 | ||
234 | 233 | ||
diff --git a/coreutils/ln.c b/coreutils/ln.c index 62496fba0..60fe39438 100644 --- a/coreutils/ln.c +++ b/coreutils/ln.c | |||
@@ -27,9 +27,9 @@ | |||
27 | #include <errno.h> | 27 | #include <errno.h> |
28 | 28 | ||
29 | 29 | ||
30 | static const char ln_usage[] = "ln [OPTION] TARGET... LINK_NAME|DIRECTORY\n" | 30 | static const char ln_usage[] = "ln [OPTION] TARGET... LINK_NAME|DIRECTORY\n\n" |
31 | "Create a link named LINK_NAME or DIRECTORY to the specified TARGET\n" | 31 | "Create a link named LINK_NAME or DIRECTORY to the specified TARGET\n\n" |
32 | "\nOptions:\n" | 32 | "Options:\n" |
33 | "\t-s\tmake symbolic links instead of hard links\n" | 33 | "\t-s\tmake symbolic links instead of hard links\n" |
34 | "\t-f\tremove existing destination files\n"; | 34 | "\t-f\tremove existing destination files\n"; |
35 | 35 | ||
diff --git a/coreutils/mkdir.c b/coreutils/mkdir.c index 0d0a90ec3..4c7ebed6a 100644 --- a/coreutils/mkdir.c +++ b/coreutils/mkdir.c | |||
@@ -26,10 +26,11 @@ | |||
26 | #include <errno.h> | 26 | #include <errno.h> |
27 | #include <sys/param.h> | 27 | #include <sys/param.h> |
28 | 28 | ||
29 | static const char mkdir_usage[] = "Usage: mkdir [OPTION] DIRECTORY...\n" | 29 | static const char mkdir_usage[] = "Usage: mkdir [OPTION] DIRECTORY...\n\n" |
30 | "Create the DIRECTORY(ies), if they do not already exist\n\n" | 30 | "Create the DIRECTORY(ies), if they do not already exist\n\n" |
31 | "-m\tset permission mode (as in chmod), not rwxrwxrwx - umask\n" | 31 | "Options:\n" |
32 | "-p\tno error if existing, make parent directories as needed\n"; | 32 | "\t-m\tset permission mode (as in chmod), not rwxrwxrwx - umask\n" |
33 | "\t-p\tno error if existing, make parent directories as needed\n"; | ||
33 | 34 | ||
34 | 35 | ||
35 | static int parentFlag = FALSE; | 36 | static int parentFlag = FALSE; |
diff --git a/coreutils/mknod.c b/coreutils/mknod.c index 81c846b98..c3389cc71 100644 --- a/coreutils/mknod.c +++ b/coreutils/mknod.c | |||
@@ -27,9 +27,9 @@ | |||
27 | #include <fcntl.h> | 27 | #include <fcntl.h> |
28 | #include <unistd.h> | 28 | #include <unistd.h> |
29 | 29 | ||
30 | static const char mknod_usage[] = "mknod file b|c|u|p major minor\n" | 30 | static const char mknod_usage[] = "mknod [OPTION]... NAME TYPE MAJOR MINOR\n\n" |
31 | "\tMake special files.\n" | 31 | "Make block or character special files.\n\n" |
32 | "\n" | 32 | "Options:\n" |
33 | "\tb:\tMake a block (buffered) device.\n" | 33 | "\tb:\tMake a block (buffered) device.\n" |
34 | "\tc or u:\tMake a character (un-buffered) device.\n" | 34 | "\tc or u:\tMake a character (un-buffered) device.\n" |
35 | "\tp:\tMake a named pipe. Major and minor are ignored for named pipes.\n"; | 35 | "\tp:\tMake a named pipe. Major and minor are ignored for named pipes.\n"; |
diff --git a/coreutils/mv.c b/coreutils/mv.c index e502250ec..b861ab7e6 100644 --- a/coreutils/mv.c +++ b/coreutils/mv.c | |||
@@ -29,7 +29,7 @@ | |||
29 | 29 | ||
30 | 30 | ||
31 | static const char mv_usage[] = "mv SOURCE DEST\n" | 31 | static const char mv_usage[] = "mv SOURCE DEST\n" |
32 | " or: mv SOURCE... DIRECTORY\n" | 32 | " or: mv SOURCE... DIRECTORY\n\n" |
33 | "Rename SOURCE to DEST, or move SOURCE(s) to DIRECTORY.\n"; | 33 | "Rename SOURCE to DEST, or move SOURCE(s) to DIRECTORY.\n"; |
34 | 34 | ||
35 | 35 | ||
diff --git a/coreutils/rm.c b/coreutils/rm.c index 077e792f9..e6132ab35 100644 --- a/coreutils/rm.c +++ b/coreutils/rm.c | |||
@@ -27,8 +27,9 @@ | |||
27 | #include <utime.h> | 27 | #include <utime.h> |
28 | #include <dirent.h> | 28 | #include <dirent.h> |
29 | 29 | ||
30 | static const char* rm_usage = "rm [OPTION]... FILE...\n" | 30 | static const char* rm_usage = "rm [OPTION]... FILE...\n\n" |
31 | "Remove (unlink) the FILE(s).\n\n" | 31 | "Remove (unlink) the FILE(s).\n\n" |
32 | "Options:\n" | ||
32 | "\t-f\tremove existing destinations, never prompt\n" | 33 | "\t-f\tremove existing destinations, never prompt\n" |
33 | "\t-r\tremove the contents of directories recursively\n"; | 34 | "\t-r\tremove the contents of directories recursively\n"; |
34 | 35 | ||
diff --git a/coreutils/rmdir.c b/coreutils/rmdir.c index 56b838736..013fef1a4 100644 --- a/coreutils/rmdir.c +++ b/coreutils/rmdir.c | |||
@@ -29,7 +29,7 @@ | |||
29 | extern int rmdir_main(int argc, char **argv) | 29 | extern int rmdir_main(int argc, char **argv) |
30 | { | 30 | { |
31 | if ( argc==1 || **(argv+1) == '-' ) { | 31 | if ( argc==1 || **(argv+1) == '-' ) { |
32 | usage( "rmdir [OPTION]... DIRECTORY...\nRemove the DIRECTORY(ies), if they are empty."); | 32 | usage( "rmdir [OPTION]... DIRECTORY...\n\nRemove the DIRECTORY(ies), if they are empty.\n"); |
33 | } | 33 | } |
34 | 34 | ||
35 | while (--argc > 0) { | 35 | while (--argc > 0) { |
diff --git a/coreutils/sleep.c b/coreutils/sleep.c index 826697824..bfbb78f61 100644 --- a/coreutils/sleep.c +++ b/coreutils/sleep.c | |||
@@ -23,8 +23,8 @@ | |||
23 | #include "internal.h" | 23 | #include "internal.h" |
24 | #include <stdio.h> | 24 | #include <stdio.h> |
25 | 25 | ||
26 | const char sleep_usage[] = " NUMBER\n" | 26 | const char sleep_usage[] = "sleep N\n\n" |
27 | "Pause for NUMBER seconds.\n"; | 27 | "Pause for N seconds.\n"; |
28 | 28 | ||
29 | extern int | 29 | extern int |
30 | sleep_main(int argc, char * * argv) | 30 | sleep_main(int argc, char * * argv) |
diff --git a/coreutils/sync.c b/coreutils/sync.c index cb4690c02..145ed1eda 100644 --- a/coreutils/sync.c +++ b/coreutils/sync.c | |||
@@ -27,7 +27,7 @@ extern int | |||
27 | sync_main(int argc, char * * argv) | 27 | sync_main(int argc, char * * argv) |
28 | { | 28 | { |
29 | if ( argc>1 && **(argv+1) == '-' ) { | 29 | if ( argc>1 && **(argv+1) == '-' ) { |
30 | usage( "sync\nWrite all buffered filesystem blocks to disk.\n"); | 30 | usage( "sync\n\nWrite all buffered filesystem blocks to disk.\n"); |
31 | } | 31 | } |
32 | exit( sync()); | 32 | exit( sync()); |
33 | } | 33 | } |
diff --git a/coreutils/touch.c b/coreutils/touch.c index b98a2e4c8..d2d3e9484 100644 --- a/coreutils/touch.c +++ b/coreutils/touch.c | |||
@@ -31,7 +31,7 @@ | |||
31 | 31 | ||
32 | 32 | ||
33 | static const char touch_usage[] = "touch [-c] file [file ...]\n\n" | 33 | static const char touch_usage[] = "touch [-c] file [file ...]\n\n" |
34 | "\tUpdate the last-modified date on the given file[s].\n"; | 34 | "Update the last-modified date on the given file[s].\n"; |
35 | 35 | ||
36 | 36 | ||
37 | 37 | ||
@@ -54,7 +54,7 @@ touch_main(int argc, char **argv) | |||
54 | create = FALSE; | 54 | create = FALSE; |
55 | break; | 55 | break; |
56 | default: | 56 | default: |
57 | fprintf(stderr, "Unknown option: %c\n", **argv); | 57 | usage( touch_usage); |
58 | exit( FALSE); | 58 | exit( FALSE); |
59 | } | 59 | } |
60 | argc--; | 60 | argc--; |
diff --git a/coreutils/uname.c b/coreutils/uname.c index b54deb345..9083edb04 100644 --- a/coreutils/uname.c +++ b/coreutils/uname.c | |||
@@ -41,8 +41,9 @@ | |||
41 | 41 | ||
42 | 42 | ||
43 | static const char uname_usage[] = | 43 | static const char uname_usage[] = |
44 | "uname [OPTION]...\n" | 44 | "uname [OPTION]...\n\n" |
45 | "Print certain system information. With no OPTION, same as -s.\n" | 45 | "Print certain system information. With no OPTION, same as -s.\n\n" |
46 | "Options:\n" | ||
46 | "\t-a\tprint all information\n" | 47 | "\t-a\tprint all information\n" |
47 | "\t-m\tthe machine (hardware) type\n" | 48 | "\t-m\tthe machine (hardware) type\n" |
48 | "\t-n\tprint the machine's network node hostname\n" | 49 | "\t-n\tprint the machine's network node hostname\n" |