Eric Andersen | 3570a34 | 2000-09-25 21:45:58 +0000 | [diff] [blame] | 1 | #include "busybox.h" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 2 | |
| 3 | #if defined BB_AR |
| 4 | const char ar_usage[] = |
Glenn L McGrath | 1c6917d | 2000-09-09 14:57:15 +0000 | [diff] [blame] | 5 | "ar -[ovR]{ptx} archive filenames \n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 6 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 7 | "\nExtract or list files from an ar archive.\n\n" |
| 8 | "Options:\n" |
Glenn L McGrath | 06aeb6c | 2000-08-25 03:50:10 +0000 | [diff] [blame] | 9 | "\t-o\t\tpreserve original dates\n" |
| 10 | "\t-p\t\textract to stdout\n" |
| 11 | "\t-t\t\tlist\n" |
| 12 | "\t-x\t\textract\n" |
| 13 | "\t-v\t\tverbosely list files processed\n" |
Glenn L McGrath | 1c6917d | 2000-09-09 14:57:15 +0000 | [diff] [blame] | 14 | "\t-R\t\trecursive action\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 15 | #endif |
| 16 | ; |
| 17 | #endif |
| 18 | |
| 19 | #if defined BB_BASENAME |
| 20 | const char basename_usage[] = |
| 21 | "basename FILE [SUFFIX]\n" |
| 22 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 23 | "\nStrips directory path and suffixes from FILE.\n" |
| 24 | "If specified, also removes any trailing SUFFIX.\n" |
| 25 | #endif |
| 26 | ; |
| 27 | #endif |
| 28 | |
| 29 | #if defined BB_CAT |
| 30 | const char cat_usage[] = |
| 31 | "cat [FILE]...\n" |
| 32 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 33 | "\nConcatenates FILE(s) and prints them to stdout.\n" |
| 34 | #endif |
| 35 | ; |
| 36 | #endif |
| 37 | |
| 38 | #if defined BB_CHMOD_CHOWN_CHGRP |
| 39 | const char chgrp_usage[] = |
| 40 | "chgrp [OPTION]... GROUP FILE...\n" |
| 41 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 42 | "\nChange the group membership of each FILE to GROUP.\n" |
| 43 | "\nOptions:\n\t-R\tChanges files and directories recursively.\n" |
| 44 | #endif |
| 45 | ; |
| 46 | #endif |
| 47 | |
| 48 | #if defined BB_CHMOD_CHOWN_CHGRP |
| 49 | const char chmod_usage[] = |
| 50 | "chmod [-R] MODE[,MODE]... FILE...\n" |
| 51 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 52 | "\nEach MODE is one or more of the letters ugoa, one of the symbols +-= and\n" |
| 53 | "one or more of the letters rwxst.\n\n" |
| 54 | "\nOptions:\n\t-R\tChanges files and directories recursively.\n" |
| 55 | #endif |
| 56 | ; |
| 57 | #endif |
| 58 | |
| 59 | #if defined BB_CHMOD_CHOWN_CHGRP |
| 60 | const char chown_usage[] = |
| 61 | "chown [OPTION]... OWNER[<.|:>[GROUP] FILE...\n" |
| 62 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 63 | "\nChange the owner and/or group of each FILE to OWNER and/or GROUP.\n" |
| 64 | "\nOptions:\n\t-R\tChanges files and directories recursively.\n" |
| 65 | #endif |
| 66 | ; |
| 67 | #endif |
| 68 | |
| 69 | #if defined BB_CHROOT |
| 70 | const char chroot_usage[] = |
| 71 | "chroot NEWROOT [COMMAND...]\n" |
| 72 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 73 | "\nRun COMMAND with root directory set to NEWROOT.\n" |
| 74 | #endif |
| 75 | ; |
| 76 | #endif |
| 77 | |
| 78 | #if defined BB_CHVT |
| 79 | const char chvt_usage[] = |
| 80 | "chvt N\n" |
| 81 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 82 | "\nChanges the foreground virtual terminal to /dev/ttyN\n" |
| 83 | #endif |
| 84 | ; |
| 85 | #endif |
| 86 | |
Matt Kraai | 2f46b66 | 2000-07-19 18:01:00 +0000 | [diff] [blame] | 87 | #if defined BB_CLEAR |
| 88 | const char clear_usage[] = |
| 89 | "clear\n" |
| 90 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 91 | "\nClear screen.\n" |
| 92 | #endif |
| 93 | ; |
| 94 | #endif |
| 95 | |
Mark Whitley | 872138d | 2000-10-09 18:56:47 +0000 | [diff] [blame] | 96 | #if defined BB_CMP |
| 97 | const char cmp_usage[] = |
| 98 | "cmp FILE1 [FILE2]\n" |
| 99 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 100 | "\nCompare files.\n" |
| 101 | #endif |
| 102 | ; |
| 103 | #endif |
| 104 | |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 105 | #if defined BB_CP_MV |
| 106 | const char cp_usage[] = |
| 107 | "cp [OPTION]... SOURCE DEST\n" |
| 108 | " or: cp [OPTION]... SOURCE... DIRECTORY\n" |
| 109 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 110 | "\nCopies SOURCE to DEST, or multiple SOURCE(s) to DIRECTORY.\n" |
| 111 | "\n" |
| 112 | "\t-a\tSame as -dpR\n" |
| 113 | "\t-d\tPreserves links\n" |
| 114 | "\t-p\tPreserves file attributes if possible\n" |
| 115 | "\t-f\tforce (implied; ignored) - always set\n" |
| 116 | "\t-R\tCopies directories recursively\n" |
| 117 | #endif |
| 118 | ; |
| 119 | #endif |
| 120 | |
| 121 | #if defined BB_CUT |
| 122 | const char cut_usage[] = |
| 123 | "cut [OPTION]... [FILE]...\n" |
| 124 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 125 | "\nPrints selected fields from each input FILE to standard output.\n\n" |
| 126 | "Options:\n" |
| 127 | "\t-b LIST\tOutput only bytes from LIST\n" |
| 128 | "\t-c LIST\tOutput only characters from LIST\n" |
| 129 | "\t-d CHAR\tUse CHAR instead of tab as the field delimiter\n" |
Pavel Roskin | 0010ee4 | 2000-07-21 15:10:57 +0000 | [diff] [blame] | 130 | "\t-s\tOutput only the lines containing delimiter\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 131 | "\t-f N\tPrint only these fields\n" |
| 132 | "\t-n\tIgnored\n" |
| 133 | #endif |
| 134 | ; |
| 135 | #endif |
| 136 | |
| 137 | #if defined BB_DATE |
| 138 | const char date_usage[] = |
| 139 | "date [OPTION]... [+FORMAT]\n" |
| 140 | " or: date [OPTION] [MMDDhhmm[[CC]YY][.ss]]\n" |
| 141 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 142 | "\nDisplays the current time in the given FORMAT, or sets the system date.\n" |
| 143 | "\nOptions:\n\t-R\tOutputs RFC-822 compliant date string\n" |
| 144 | "\t-s\tSets time described by STRING\n" |
| 145 | "\t-u\tPrints or sets Coordinated Universal Time\n" |
| 146 | #endif |
| 147 | ; |
| 148 | #endif |
| 149 | |
| 150 | #if defined BB_DC |
| 151 | const char dc_usage[] = |
| 152 | "dc expression ...\n" |
| 153 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 154 | "\nThis is a Tiny RPN calculator that understands the\n" |
| 155 | "following operations: +, -, /, *, and, or, not, eor.\n" |
| 156 | "i.e. 'dc 2 2 add' -> 4, and 'dc 8 8 \\* 2 2 + /' -> 16\n" |
| 157 | #endif |
| 158 | ; |
| 159 | #endif |
| 160 | |
| 161 | #if defined BB_DD |
| 162 | const char dd_usage[] = |
| 163 | "dd [if=FILE] [of=FILE] [bs=N] [count=N] [skip=N] [seek=N]\n" |
| 164 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 165 | "\nCopy a file, converting and formatting according to options\n\n" |
| 166 | "\tif=FILE\tread from FILE instead of stdin\n" |
| 167 | "\tof=FILE\twrite to FILE instead of stdout\n" |
| 168 | "\tbs=N\tread and write N bytes at a time\n" |
| 169 | "\tcount=N\tcopy only N input blocks\n" |
| 170 | "\tskip=N\tskip N input blocks\n" |
| 171 | "\tseek=N\tskip N output blocks\n" |
Glenn L McGrath | 605a819 | 2000-09-11 00:33:09 +0000 | [diff] [blame] | 172 | "\tconv=notrunc\t dont truncate of at end of write\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 173 | "\n" |
| 174 | "Numbers may be suffixed by w (x2), k (x1024), b (x512), or M (x1024^2)\n" |
| 175 | #endif |
| 176 | ; |
| 177 | #endif |
| 178 | |
| 179 | #if defined BB_DEALLOCVT |
| 180 | const char deallocvt_usage[] = |
| 181 | "deallocvt N\n" |
| 182 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 183 | "\nDeallocate unused virtual terminal /dev/ttyN\n" |
| 184 | #endif |
| 185 | ; |
| 186 | #endif |
| 187 | |
| 188 | #if defined BB_DF |
| 189 | const char df_usage[] = |
| 190 | "df [filesystem ...]\n" |
| 191 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 192 | "\nPrint the filesystem space used and space available.\n" |
| 193 | #endif |
| 194 | ; |
| 195 | #endif |
| 196 | |
| 197 | #if defined BB_DIRNAME |
| 198 | const char dirname_usage[] = |
| 199 | "dirname [FILENAME ...]\n" |
| 200 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 201 | "\nStrips non-directory suffix from FILENAME\n" |
| 202 | #endif |
| 203 | ; |
| 204 | #endif |
| 205 | |
| 206 | #if defined BB_DMESG |
| 207 | const char dmesg_usage[] = |
| 208 | "dmesg [-c] [-n LEVEL] [-s SIZE]\n" |
| 209 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 210 | "\nPrints or controls the kernel ring buffer\n\n" |
| 211 | "Options:\n" |
| 212 | "\t-c\t\tClears the ring buffer's contents after printing\n" |
| 213 | "\t-n LEVEL\tSets console logging level\n" |
| 214 | "\t-s SIZE\t\tUse a buffer of size SIZE\n" |
| 215 | #endif |
| 216 | ; |
| 217 | #endif |
| 218 | |
Eric Andersen | cff3fe3 | 2000-09-20 19:22:26 +0000 | [diff] [blame] | 219 | #if defined BB_DOS2UNIX |
| 220 | const char dos2unix_usage[] = |
| 221 | "dos2unix < dosfile > unixfile\n" |
| 222 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 223 | "\nConverts a text file from dos format to unix format.\n" |
| 224 | #endif |
| 225 | ; |
| 226 | #endif |
| 227 | |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 228 | #if defined BB_DU |
| 229 | const char du_usage[] = |
| 230 | "du [OPTION]... [FILE]...\n" |
| 231 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 232 | "\nSummarizes disk space used for each FILE and/or directory.\n" |
| 233 | "Disk space is printed in units of 1024 bytes.\n\n" |
| 234 | "Options:\n" |
| 235 | "\t-l\tcount sizes many times if hard linked\n" |
| 236 | "\t-s\tdisplay only a total for each argument\n" |
| 237 | #endif |
| 238 | ; |
| 239 | #endif |
| 240 | |
| 241 | #if defined BB_DUMPKMAP |
| 242 | const char dumpkmap_usage[] = |
Eric Andersen | 18a1014 | 2000-09-01 16:12:57 +0000 | [diff] [blame] | 243 | "dumpkmap > keymap\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 244 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 245 | "\nPrints out a binary keyboard translation table to standard input.\n" |
| 246 | #endif |
| 247 | ; |
| 248 | #endif |
| 249 | |
| 250 | #if defined BB_DUTMP |
| 251 | const char dutmp_usage[] = |
| 252 | "dutmp [FILE]\n" |
| 253 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 254 | "\nDump utmp file format (pipe delimited) from FILE\n" |
| 255 | "or stdin to stdout. (i.e. 'dutmp /var/run/utmp')\n" |
| 256 | #endif |
| 257 | ; |
| 258 | #endif |
| 259 | |
| 260 | #if defined BB_ECHO |
| 261 | const char echo_usage[] = |
| 262 | "echo [-neE] [ARG ...]\n" |
| 263 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 264 | "\nPrints the specified ARGs to stdout\n\n" |
| 265 | "Options:\n" |
| 266 | "\t-n\tsuppress trailing newline\n" |
| 267 | "\t-e\tinterpret backslash-escaped characters (i.e. \\t=tab etc)\n" |
| 268 | "\t-E\tdisable interpretation of backslash-escaped characters\n" |
| 269 | #endif |
| 270 | ; |
| 271 | #endif |
| 272 | |
Eric Andersen | 1b355eb | 2000-09-05 17:37:48 +0000 | [diff] [blame] | 273 | #if defined BB_EXPR |
| 274 | const char expr_usage[] = |
| 275 | "expr EXPRESSION\n" |
| 276 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 277 | "\nPrints the value of EXPRESSION to standard output.\n\n" |
| 278 | "EXPRESSION may be:\n" |
| 279 | "ARG1 | ARG2 ARG1 if it is neither null nor 0, otherwise ARG2\n" |
| 280 | "ARG1 & ARG2 ARG1 if neither argument is null or 0, otherwise 0\n" |
| 281 | "ARG1 < ARG2 ARG1 is less than ARG2\n" |
| 282 | "ARG1 <= ARG2 ARG1 is less than or equal to ARG2\n" |
| 283 | "ARG1 = ARG2 ARG1 is equal to ARG2\n" |
| 284 | "ARG1 != ARG2 ARG1 is unequal to ARG2\n" |
| 285 | "ARG1 >= ARG2 ARG1 is greater than or equal to ARG2\n" |
| 286 | "ARG1 > ARG2 ARG1 is greater than ARG2\n" |
| 287 | "ARG1 + ARG2 arithmetic sum of ARG1 and ARG2\n" |
| 288 | "ARG1 - ARG2 arithmetic difference of ARG1 and ARG2\n" |
| 289 | "ARG1 * ARG2 arithmetic product of ARG1 and ARG2\n" |
| 290 | "ARG1 / ARG2 arithmetic quotient of ARG1 divided by ARG2\n" |
| 291 | "ARG1 % ARG2 arithmetic remainder of ARG1 divided by ARG2\n" |
| 292 | "STRING : REGEXP anchored pattern match of REGEXP in STRING\n" |
| 293 | "match STRING REGEXP same as STRING : REGEXP\n" |
| 294 | "substr STRING POS LENGTH substring of STRING, POS counted from 1\n" |
| 295 | "index STRING CHARS index in STRING where any CHARS is found, or 0\n" |
| 296 | "length STRING length of STRING\n" |
| 297 | "quote TOKEN interpret TOKEN as a string, even if it is a \n" |
| 298 | " keyword like `match' or an operator like `/'\n" |
| 299 | "( EXPRESSION ) value of EXPRESSION\n\n" |
| 300 | "Beware that many operators need to be escaped or quoted for shells.\n" |
| 301 | "Comparisons are arithmetic if both ARGs are numbers, else\n" |
| 302 | "lexicographical. Pattern matches return the string matched between \n" |
| 303 | "\\( and \\) or null; if \\( and \\) are not used, they return the number \n" |
| 304 | "of characters matched or 0.\n" |
| 305 | |
| 306 | #endif |
| 307 | ; |
| 308 | #endif |
| 309 | |
| 310 | |
Matt Kraai | 2f46b66 | 2000-07-19 18:01:00 +0000 | [diff] [blame] | 311 | #if defined BB_TRUE_FALSE |
| 312 | const char false_usage[] = |
| 313 | "false\n" |
| 314 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 315 | "\nReturn an exit code of FALSE (1).\n" |
| 316 | #endif |
| 317 | ; |
| 318 | #endif |
| 319 | |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 320 | #if defined BB_FDFLUSH |
| 321 | const char fdflush_usage[] = |
| 322 | "fdflush DEVICE\n" |
| 323 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 324 | "\nForces floppy disk drive to detect disk change\n" |
| 325 | #endif |
| 326 | ; |
| 327 | #endif |
| 328 | |
| 329 | #if defined BB_FIND |
| 330 | const char find_usage[] = |
| 331 | "find [PATH...] [EXPRESSION]\n" |
| 332 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 333 | "\nSearch for files in a directory hierarchy. The default PATH is\n" |
| 334 | "the current directory; default EXPRESSION is '-print'\n\n" |
| 335 | "\nEXPRESSION may consist of:\n" |
| 336 | "\t-follow\t\tDereference symbolic links.\n" |
| 337 | "\t-name PATTERN\tFile name (leading directories removed) matches PATTERN.\n" |
| 338 | "\t-print\t\tprint the full file name followed by a newline to stdout.\n" |
| 339 | #endif |
| 340 | ; |
| 341 | #endif |
| 342 | |
| 343 | #if defined BB_FREE |
| 344 | const char free_usage[] = |
| 345 | "free\n" |
| 346 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 347 | "\nDisplays the amount of free and used system memory\n" |
| 348 | #endif |
| 349 | ; |
| 350 | #endif |
| 351 | |
| 352 | #if defined BB_FREERAMDISK |
| 353 | const char freeramdisk_usage[] = |
| 354 | "freeramdisk DEVICE\n" |
| 355 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 356 | "\nFrees all memory used by the specified ramdisk.\n" |
| 357 | #endif |
| 358 | ; |
| 359 | #endif |
| 360 | |
| 361 | #if defined BB_FSCK_MINIX |
| 362 | const char fsck_minix_usage[] = |
| 363 | "Usage: fsck.minix [-larvsmf] /dev/name\n" |
| 364 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 365 | "\nPerforms a consistency check for MINIX filesystems.\n\n" |
| 366 | "Options:\n" |
| 367 | "\t-l\tLists all filenames\n" |
| 368 | "\t-r\tPerform interactive repairs\n" |
| 369 | "\t-a\tPerform automatic repairs\n" |
| 370 | "\t-v\tverbose\n" |
| 371 | "\t-s\tOutputs super-block information\n" |
| 372 | "\t-m\tActivates MINIX-like \"mode not cleared\" warnings\n" |
| 373 | "\t-f\tForce file system check.\n\n" |
| 374 | #endif |
| 375 | ; |
| 376 | #endif |
| 377 | |
| 378 | #if defined BB_GREP |
| 379 | const char grep_usage[] = |
| 380 | "grep [-ihHnqvs] pattern [files...]\n" |
| 381 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 382 | "\nSearch for PATTERN in each FILE or standard input.\n\n" |
| 383 | "Options:\n" |
| 384 | "\t-H\tprefix output lines with filename where match was found\n" |
| 385 | "\t-h\tsuppress the prefixing filename on output\n" |
| 386 | "\t-i\tignore case distinctions\n" |
| 387 | "\t-n\tprint line number with output lines\n" |
| 388 | "\t-q\tbe quiet. Returns 0 if result was found, 1 otherwise\n" |
| 389 | "\t-v\tselect non-matching lines\n" |
| 390 | "\t-s\tsuppress file open/read error messages\n\n" |
| 391 | #endif |
| 392 | ; |
| 393 | #endif |
| 394 | |
| 395 | #if defined BB_GUNZIP |
| 396 | const char gunzip_usage[] = |
| 397 | "gunzip [OPTION]... FILE\n" |
| 398 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 399 | "\nUncompress FILE (or standard input if FILE is '-').\n\n" |
| 400 | "Options:\n" |
| 401 | "\t-c\tWrite output to standard output\n" |
| 402 | "\t-t\tTest compressed file integrity\n" |
| 403 | #endif |
| 404 | ; |
| 405 | #endif |
| 406 | |
| 407 | #if defined BB_GZIP |
| 408 | const char gzip_usage[] = |
| 409 | "gzip [OPTION]... FILE\n" |
| 410 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 411 | "\nCompress FILE with maximum compression.\n" |
| 412 | "When FILE is '-', reads standard input. Implies -c.\n\n" |
| 413 | "Options:\n" |
| 414 | "\t-c\tWrite output to standard output instead of FILE.gz\n" |
| 415 | #endif |
| 416 | ; |
| 417 | #endif |
| 418 | |
Matt Kraai | 2f46b66 | 2000-07-19 18:01:00 +0000 | [diff] [blame] | 419 | #if defined BB_HALT |
| 420 | const char halt_usage[] = |
| 421 | "halt\n" |
| 422 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 423 | "\nHalt the system.\n" |
| 424 | #endif |
| 425 | ; |
Matt Kraai | 8690572 | 2000-07-19 18:20:02 +0000 | [diff] [blame] | 426 | #endif |
Matt Kraai | 2f46b66 | 2000-07-19 18:01:00 +0000 | [diff] [blame] | 427 | |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 428 | #if defined BB_HEAD |
| 429 | const char head_usage[] = |
| 430 | "head [OPTION] [FILE]...\n" |
| 431 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 432 | "\nPrint first 10 lines of each FILE to standard output.\n" |
| 433 | "With more than one FILE, precede each with a header giving the\n" |
| 434 | "file name. With no FILE, or when FILE is -, read standard input.\n\n" |
| 435 | |
| 436 | "Options:\n" "\t-n NUM\t\tPrint first NUM lines instead of first 10\n" |
| 437 | #endif |
| 438 | ; |
| 439 | #endif |
| 440 | |
Matt Kraai | 2f46b66 | 2000-07-19 18:01:00 +0000 | [diff] [blame] | 441 | #if defined BB_HOSTID |
| 442 | const char hostid_usage[] = |
| 443 | "hostid\n" |
| 444 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 445 | "\nPrint out a unique 32-bit identifier for the machine.\n" |
| 446 | #endif |
| 447 | ; |
| 448 | #endif |
| 449 | |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 450 | #if defined BB_HOSTNAME |
| 451 | const char hostname_usage[] = |
| 452 | "hostname [OPTION] {hostname | -F file}\n" |
| 453 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 454 | "\nGet or set the hostname or DNS domain name. If a hostname is given\n" |
| 455 | "(or a file with the -F parameter), the host name will be set.\n\n" |
| 456 | "Options:\n" |
| 457 | "\t-s\t\tShort\n" |
| 458 | |
| 459 | "\t-i\t\tAddresses for the hostname\n" |
| 460 | "\t-d\t\tDNS domain name\n" |
Eric Andersen | 0d5835a | 2000-10-12 22:30:31 +0000 | [diff] [blame^] | 461 | "\t-F, --file FILE\tUse the contents of FILE to specify the hostname\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 462 | #endif |
| 463 | ; |
| 464 | #endif |
| 465 | |
| 466 | #if defined BB_ID |
| 467 | const char id_usage[] = |
| 468 | "id [OPTIONS]... [USERNAME]\n" |
| 469 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 470 | "\nPrint information for USERNAME or the current user\n\n" |
| 471 | "Options:\n" |
| 472 | "\t-g\tprints only the group ID\n" |
| 473 | "\t-u\tprints only the user ID\n" |
| 474 | "\t-r\tprints the real user ID instead of the effective ID (with -ug)\n\n" |
| 475 | #endif |
| 476 | ; |
| 477 | #endif |
| 478 | |
| 479 | #if defined BB_INSMOD |
| 480 | const char insmod_usage[] = |
| 481 | "insmod [OPTION]... MODULE [symbol=value]...\n" |
| 482 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 483 | "\nLoads the specified kernel modules into the kernel.\n\n" |
| 484 | "Options:\n" |
| 485 | "\t-f\tForce module to load into the wrong kernel version.\n" |
| 486 | "\t-k\tMake module autoclean-able.\n" |
| 487 | "\t-v\tverbose output\n" "\t-x\tdo not export externs\n" |
| 488 | #endif |
| 489 | ; |
| 490 | #endif |
| 491 | |
| 492 | #if defined BB_KILL |
| 493 | const char kill_usage[] = |
| 494 | "kill [-signal] process-id [process-id ...]\n" |
| 495 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 496 | "\nSend a signal (default is SIGTERM) to the specified process(es).\n\n" |
| 497 | "Options:\n" "\t-l\tList all signal names and numbers.\n\n" |
| 498 | #endif |
| 499 | ; |
| 500 | #endif |
| 501 | |
| 502 | #if defined BB_KILLALL |
| 503 | const char killall_usage[] = |
| 504 | "killall [-signal] process-name [process-name ...]\n" |
| 505 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 506 | "\nSend a signal (default is SIGTERM) to the specified process(es).\n\n" |
| 507 | "Options:\n" "\t-l\tList all signal names and numbers.\n\n" |
| 508 | #endif |
| 509 | ; |
| 510 | #endif |
| 511 | |
| 512 | #if defined BB_LENGTH |
| 513 | const char length_usage[] = |
| 514 | "length STRING\n" |
| 515 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 516 | "\nPrints out the length of the specified STRING.\n" |
| 517 | #endif |
| 518 | ; |
| 519 | #endif |
| 520 | |
| 521 | #if defined BB_LN |
| 522 | const char ln_usage[] = |
| 523 | "ln [OPTION] TARGET... LINK_NAME|DIRECTORY\n" |
| 524 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 525 | "\nCreate a link named LINK_NAME or DIRECTORY to the specified TARGET\n" |
| 526 | "\nYou may use '--' to indicate that all following arguments are non-options.\n\n" |
| 527 | "Options:\n" |
| 528 | "\t-s\tmake symbolic links instead of hard links\n" |
| 529 | |
| 530 | "\t-f\tremove existing destination files\n" |
| 531 | "\t-n\tno dereference symlinks - treat like normal file\n" |
| 532 | #endif |
| 533 | ; |
| 534 | #endif |
| 535 | |
| 536 | #if defined BB_LOADACM |
| 537 | const char loadacm_usage[] = |
Eric Andersen | 18a1014 | 2000-09-01 16:12:57 +0000 | [diff] [blame] | 538 | "loadacm < mapfile\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 539 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 540 | "\nLoads an acm from standard input.\n" |
| 541 | #endif |
| 542 | ; |
| 543 | #endif |
| 544 | |
| 545 | #if defined BB_LOADFONT |
| 546 | const char loadfont_usage[] = |
Eric Andersen | 18a1014 | 2000-09-01 16:12:57 +0000 | [diff] [blame] | 547 | "loadfont < font\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 548 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 549 | "Loads a console font from standard input.\n" |
| 550 | #endif |
| 551 | ; |
| 552 | #endif |
| 553 | |
| 554 | #if defined BB_LOADKMAP |
| 555 | const char loadkmap_usage[] = |
Eric Andersen | 18a1014 | 2000-09-01 16:12:57 +0000 | [diff] [blame] | 556 | "loadkmap < keymap\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 557 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 558 | "\nLoads a binary keyboard translation table from standard input.\n" |
| 559 | #endif |
| 560 | ; |
| 561 | #endif |
| 562 | |
| 563 | #if defined BB_LOGGER |
| 564 | const char logger_usage[] = |
| 565 | "logger [OPTION]... [MESSAGE]\n" |
| 566 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 567 | "\nWrite MESSAGE to the system log. If MESSAGE is '-', log stdin.\n\n" |
| 568 | "Options:\n" |
| 569 | "\t-s\tLog to stderr as well as the system log.\n" |
| 570 | "\t-t\tLog using the specified tag (defaults to user name).\n" |
| 571 | |
| 572 | "\t-p\tEnter the message with the specified priority.\n" |
| 573 | "\t\tThis may be numerical or a ``facility.level'' pair.\n" |
| 574 | #endif |
| 575 | ; |
| 576 | #endif |
| 577 | |
| 578 | #if defined BB_LOGNAME |
| 579 | const char logname_usage[] = |
| 580 | "logname\n" |
| 581 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 582 | "\nPrint the name of the current user.\n" |
| 583 | #endif |
| 584 | ; |
| 585 | #endif |
| 586 | |
| 587 | #if defined BB_LS |
| 588 | const char ls_usage[] = |
Eric Andersen | 11c6552 | 2000-09-07 17:24:47 +0000 | [diff] [blame] | 589 | "ls [-1Aa" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 590 | #ifdef BB_FEATURE_LS_TIMESTAMPS |
| 591 | "c" |
| 592 | #endif |
Eric Andersen | 11c6552 | 2000-09-07 17:24:47 +0000 | [diff] [blame] | 593 | "Cd" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 594 | #ifdef BB_FEATURE_LS_TIMESTAMPS |
| 595 | "e" |
| 596 | #endif |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 597 | #ifdef BB_FEATURE_LS_FILETYPES |
| 598 | "F" |
| 599 | #endif |
Eric Andersen | 11c6552 | 2000-09-07 17:24:47 +0000 | [diff] [blame] | 600 | "iln" |
| 601 | #ifdef BB_FEATURE_LS_FILETYPES |
| 602 | "p" |
| 603 | #endif |
Eric Andersen | 5b17693 | 2000-09-22 20:22:28 +0000 | [diff] [blame] | 604 | #ifdef BB_FEATURE_LS_FOLLOWLINKS |
| 605 | "L" |
| 606 | #endif |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 607 | #ifdef BB_FEATURE_LS_RECURSIVE |
| 608 | "R" |
| 609 | #endif |
Eric Andersen | 11c6552 | 2000-09-07 17:24:47 +0000 | [diff] [blame] | 610 | #ifdef BB_FEATURE_LS_SORTFILES |
| 611 | "rS" |
| 612 | #endif |
| 613 | "s" |
| 614 | #ifdef BB_FEATURE_AUTOWIDTH |
| 615 | "T" |
| 616 | #endif |
| 617 | #ifdef BB_FEATURE_LS_TIMESTAMPS |
| 618 | "tu" |
| 619 | #endif |
| 620 | #ifdef BB_FEATURE_LS_SORTFILES |
| 621 | "v" |
| 622 | #endif |
| 623 | #ifdef BB_FEATURE_AUTOWIDTH |
| 624 | "w" |
| 625 | #endif |
| 626 | "x" |
| 627 | #ifdef BB_FEATURE_LS_SORTFILES |
| 628 | "X" |
| 629 | #endif |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 630 | "] [filenames...]\n" |
| 631 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 632 | "\nList directory contents\n\n" |
| 633 | "Options:\n" |
Eric Andersen | 11c6552 | 2000-09-07 17:24:47 +0000 | [diff] [blame] | 634 | "\t-1\tlist files in a single column\n" |
| 635 | "\t-A\tdo not list implied . and ..\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 636 | "\t-a\tdo not hide entries starting with .\n" |
Eric Andersen | 11c6552 | 2000-09-07 17:24:47 +0000 | [diff] [blame] | 637 | "\t-C\tlist entries by columns\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 638 | #ifdef BB_FEATURE_LS_TIMESTAMPS |
| 639 | "\t-c\twith -l: show ctime (the time of last\n" |
| 640 | "\t\tmodification of file status information)\n" |
| 641 | #endif |
| 642 | "\t-d\tlist directory entries instead of contents\n" |
| 643 | #ifdef BB_FEATURE_LS_TIMESTAMPS |
| 644 | "\t-e\tlist both full date and full time\n" |
| 645 | #endif |
Eric Andersen | 11c6552 | 2000-09-07 17:24:47 +0000 | [diff] [blame] | 646 | #ifdef BB_FEATURE_LS_FILETYPES |
| 647 | "\t-F\tappend indicator (one of */=@|) to entries\n" |
| 648 | #endif |
| 649 | "\t-i\tlist the i-node for each file\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 650 | "\t-l\tuse a long listing format\n" |
| 651 | "\t-n\tlist numeric UIDs and GIDs instead of names\n" |
| 652 | #ifdef BB_FEATURE_LS_FILETYPES |
| 653 | "\t-p\tappend indicator (one of /=@|) to entries\n" |
| 654 | #endif |
Eric Andersen | 5b17693 | 2000-09-22 20:22:28 +0000 | [diff] [blame] | 655 | #ifdef BB_FEATURE_LS_FOLLOWLINKS |
| 656 | "\t-L\tlist entries pointed to by symbolic links\n" |
| 657 | #endif |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 658 | #ifdef BB_FEATURE_LS_RECURSIVE |
| 659 | "\t-R\tlist subdirectories recursively\n" |
| 660 | #endif |
Eric Andersen | 11c6552 | 2000-09-07 17:24:47 +0000 | [diff] [blame] | 661 | #ifdef BB_FEATURE_LS_SORTFILES |
| 662 | "\t-r\tsort the listing in reverse order\n" |
| 663 | "\t-S\tsort the listing by file size\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 664 | #endif |
Eric Andersen | 11c6552 | 2000-09-07 17:24:47 +0000 | [diff] [blame] | 665 | "\t-s\tlist the size of each file, in blocks\n" |
| 666 | #ifdef BB_FEATURE_AUTOWIDTH |
| 667 | "\t-T NUM\tassume Tabstop every NUM columns\n" |
| 668 | #endif |
| 669 | #ifdef BB_FEATURE_LS_TIMESTAMPS |
| 670 | "\t-t\twith -l: show modification time (the time of last\n" |
| 671 | "\t\tchange of the file)\n" |
| 672 | "\t-u\twith -l: show access time (the time of last\n" |
| 673 | "\t\taccess of the file)\n" |
| 674 | #endif |
| 675 | #ifdef BB_FEATURE_LS_SORTFILES |
| 676 | "\t-v\tsort the listing by version\n" |
| 677 | #endif |
| 678 | #ifdef BB_FEATURE_AUTOWIDTH |
| 679 | "\t-w NUM\tassume the terminal is NUM columns wide\n" |
| 680 | #endif |
| 681 | "\t-x\tlist entries by lines instead of by columns\n" |
| 682 | #ifdef BB_FEATURE_LS_SORTFILES |
| 683 | "\t-X\tsort the listing by extension\n" |
| 684 | #endif |
| 685 | #endif /* BB_FEATURE_TRIVIAL_HELP */ |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 686 | ; |
Eric Andersen | 11c6552 | 2000-09-07 17:24:47 +0000 | [diff] [blame] | 687 | #endif /* BB_LS */ |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 688 | |
Matt Kraai | 2f46b66 | 2000-07-19 18:01:00 +0000 | [diff] [blame] | 689 | #if defined BB_LSMOD |
| 690 | const char lsmod_usage[] = |
| 691 | "lsmod\n" |
| 692 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 693 | "\nList the currently loaded kernel modules.\n" |
| 694 | #endif |
| 695 | ; |
| 696 | #endif |
| 697 | |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 698 | #if defined BB_MAKEDEVS |
| 699 | const char makedevs_usage[] = |
| 700 | "makedevs NAME TYPE MAJOR MINOR FIRST LAST [s]\n" |
| 701 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 702 | "\nCreates a range of block or character special files\n\n" |
| 703 | "TYPEs include:\n" |
| 704 | "\tb:\tMake a block (buffered) device.\n" |
| 705 | "\tc or u:\tMake a character (un-buffered) device.\n" |
| 706 | "\tp:\tMake a named pipe. MAJOR and MINOR are ignored for named pipes.\n\n" |
| 707 | "FIRST specifies the number appended to NAME to create the first device.\n" |
| 708 | "LAST specifies the number of the last item that should be created.\n" |
| 709 | "If 's' is the last argument, the base device is created as well.\n\n" |
| 710 | "For example:\n" |
| 711 | "\tmakedevs /dev/ttyS c 4 66 2 63 -> ttyS2-ttyS63\n" |
| 712 | "\tmakedevs /dev/hda b 3 0 0 8 s -> hda,hda1-hda8\n" |
| 713 | #endif |
| 714 | ; |
| 715 | #endif |
| 716 | |
| 717 | #if defined BB_MD5SUM |
| 718 | const char md5sum_usage[] = |
| 719 | "md5sum [OPTION] [FILE]...\n" |
| 720 | "or: md5sum [OPTION] -c [FILE]\n" |
| 721 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 722 | "\nPrint or check MD5 checksums.\n\n" |
| 723 | "Options:\n" |
| 724 | "With no FILE, or when FILE is -, read standard input.\n\n" |
| 725 | "\t-b\tread files in binary mode\n" |
| 726 | "\t-c\tcheck MD5 sums against given list\n" |
| 727 | "\t-t\tread files in text mode (default)\n" |
| 728 | "\t-g\tread a string\n" |
| 729 | "\nThe following two options are useful only when verifying checksums:\n" |
| 730 | "\t-s,\tdon't output anything, status code shows success\n" |
| 731 | "\t-w,\twarn about improperly formated MD5 checksum lines\n" |
| 732 | #endif |
| 733 | ; |
| 734 | #endif |
| 735 | |
| 736 | #if defined BB_MKDIR |
| 737 | const char mkdir_usage[] = |
| 738 | "mkdir [OPTION] DIRECTORY...\n" |
| 739 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 740 | "\nCreate the DIRECTORY(ies), if they do not already exist\n\n" |
| 741 | "Options:\n" |
| 742 | |
| 743 | "\t-m\tset permission mode (as in chmod), not rwxrwxrwx - umask\n" |
| 744 | "\t-p\tno error if existing, make parent directories as needed\n" |
| 745 | #endif |
| 746 | ; |
| 747 | #endif |
| 748 | |
| 749 | #if defined BB_MKFIFO |
| 750 | const char mkfifo_usage[] = |
| 751 | "mkfifo [OPTIONS] name\n" |
| 752 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 753 | "\nCreates a named pipe (identical to 'mknod name p')\n\n" |
| 754 | "Options:\n" |
| 755 | "\t-m\tcreate the pipe using the specified mode (default a=rw)\n" |
| 756 | #endif |
| 757 | ; |
| 758 | #endif |
| 759 | |
| 760 | #if defined BB_MKFS_MINIX |
| 761 | const char mkfs_minix_usage[] = |
| 762 | "mkfs.minix [-c | -l filename] [-nXX] [-iXX] /dev/name [blocks]\n" |
| 763 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 764 | "\nMake a MINIX filesystem.\n\n" |
| 765 | "Options:\n" |
| 766 | "\t-c\t\tCheck the device for bad blocks\n" |
| 767 | "\t-n [14|30]\tSpecify the maximum length of filenames\n" |
| 768 | "\t-i INODES\tSpecify the number of inodes for the filesystem\n" |
| 769 | "\t-l FILENAME\tRead the bad blocks list from FILENAME\n" |
| 770 | "\t-v\t\tMake a Minix version 2 filesystem\n\n" |
| 771 | #endif |
| 772 | ; |
| 773 | #endif |
| 774 | |
| 775 | #if defined BB_MKNOD |
| 776 | const char mknod_usage[] = |
| 777 | "mknod [OPTIONS] NAME TYPE MAJOR MINOR\n" |
| 778 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 779 | "\nCreate a special file (block, character, or pipe).\n\n" |
| 780 | "Options:\n" |
| 781 | "\t-m\tcreate the special file using the specified mode (default a=rw)\n\n" |
| 782 | "TYPEs include:\n" |
| 783 | "\tb:\tMake a block (buffered) device.\n" |
| 784 | "\tc or u:\tMake a character (un-buffered) device.\n" |
| 785 | "\tp:\tMake a named pipe. MAJOR and MINOR are ignored for named pipes.\n" |
| 786 | #endif |
| 787 | ; |
| 788 | #endif |
| 789 | |
| 790 | #if defined BB_MKSWAP |
| 791 | const char mkswap_usage[] = |
| 792 | "mkswap [-c] [-v0|-v1] device [block-count]\n" |
| 793 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 794 | "\nPrepare a disk partition to be used as a swap partition.\n\n" |
| 795 | "Options:\n" "\t-c\t\tCheck for read-ability.\n" |
| 796 | "\t-v0\t\tMake version 0 swap [max 128 Megs].\n" |
| 797 | "\t-v1\t\tMake version 1 swap [big!] (default for kernels > 2.1.117).\n" |
| 798 | |
| 799 | "\tblock-count\tNumber of block to use (default is entire partition).\n" |
| 800 | #endif |
| 801 | ; |
| 802 | #endif |
| 803 | |
| 804 | #if defined BB_MKTEMP |
| 805 | const char mktemp_usage[] = |
| 806 | "mktemp [-q] TEMPLATE\n" |
| 807 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 808 | "\nCreates a temporary file with its name based on TEMPLATE.\n" |
| 809 | "TEMPLATE is any name with six `Xs' (i.e. /tmp/temp.XXXXXX).\n" |
| 810 | #endif |
| 811 | ; |
| 812 | #endif |
| 813 | |
| 814 | #if defined BB_MORE |
| 815 | const char more_usage[] = |
| 816 | "more [FILE ...]\n" |
| 817 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 818 | "\nMore is a filter for viewing FILE one screenful at a time.\n" |
| 819 | #endif |
| 820 | ; |
| 821 | #endif |
| 822 | |
| 823 | #if defined BB_MOUNT |
| 824 | const char mount_usage[] = |
| 825 | "mount [flags] device directory [-o options,more-options]\n" |
| 826 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 827 | "\nMount a filesystem\n\n" |
| 828 | "Flags:\n" |
| 829 | "\t-a:\t\tMount all filesystems in fstab.\n" |
| 830 | #ifdef BB_MTAB |
| 831 | "\t-f:\t\t\"Fake\" mount. Add entry to mount table but don't mount it.\n" |
| 832 | "\t-n:\t\tDon't write a mount table entry.\n" |
| 833 | #endif |
| 834 | "\t-o option:\tOne of many filesystem options, listed below.\n" |
| 835 | "\t-r:\t\tMount the filesystem read-only.\n" |
| 836 | "\t-t fs-type:\tSpecify the filesystem type.\n" |
| 837 | "\t-w:\t\tMount for reading and writing (default).\n" |
| 838 | "\n" |
| 839 | "Options for use with the \"-o\" flag:\n" |
| 840 | "\tasync/sync:\tWrites are asynchronous / synchronous.\n" |
| 841 | "\tatime/noatime:\tEnable / disable updates to inode access times.\n" |
| 842 | "\tdev/nodev:\tAllow use of special device files / disallow them.\n" |
| 843 | "\texec/noexec:\tAllow use of executable files / disallow them.\n" |
| 844 | #if defined BB_FEATURE_MOUNT_LOOP |
| 845 | "\tloop:\t\tMounts a file via loop device.\n" |
| 846 | #endif |
| 847 | "\tsuid/nosuid:\tAllow set-user-id-root programs / disallow them.\n" |
| 848 | "\tremount:\tRe-mount a currently-mounted filesystem, changing its flags.\n" |
| 849 | "\tro/rw:\t\tMount for read-only / read-write.\n" |
| 850 | "\nThere are EVEN MORE flags that are specific to each filesystem.\n" |
| 851 | "You'll have to see the written documentation for those.\n" |
| 852 | #endif |
| 853 | ; |
| 854 | #endif |
| 855 | |
| 856 | #if defined BB_MT |
| 857 | const char mt_usage[] = |
| 858 | "mt [-f device] opcode value\n" |
| 859 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 860 | "\nControl magnetic tape drive operation\n" |
Eric Andersen | 8cbac44 | 2000-08-11 20:14:11 +0000 | [diff] [blame] | 861 | "\nAvailable Opcodes:\n\n" |
| 862 | "bsf bsfm bsr bss datacompression drvbuffer eof eom erase\n" |
| 863 | "fsf fsfm fsr fss load lock mkpart nop offline ras1 ras2\n" |
| 864 | "ras3 reset retension rew rewoffline seek setblk setdensity\n" |
| 865 | "setpart tell unload unlock weof wset\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 866 | #endif |
| 867 | ; |
| 868 | #endif |
| 869 | |
| 870 | #if defined BB_CP_MV |
| 871 | const char mv_usage[] = |
| 872 | "mv SOURCE DEST\n" |
| 873 | " or: mv SOURCE... DIRECTORY\n" |
| 874 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 875 | "\nRename SOURCE to DEST, or move SOURCE(s) to DIRECTORY.\n" |
| 876 | #endif |
| 877 | ; |
| 878 | #endif |
| 879 | |
| 880 | #if defined BB_NC |
| 881 | const char nc_usage[] = |
| 882 | "nc [IP] [port]\n" |
| 883 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 884 | "\nNetcat opens a pipe to IP:port\n" |
| 885 | #endif |
| 886 | ; |
| 887 | #endif |
| 888 | |
| 889 | #if defined BB_NSLOOKUP |
| 890 | const char nslookup_usage[] = |
| 891 | "nslookup [HOST]\n" |
| 892 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 893 | "\nQueries the nameserver for the IP address of the given HOST\n" |
| 894 | #endif |
| 895 | ; |
| 896 | #endif |
| 897 | |
| 898 | #if defined BB_PING |
| 899 | #if defined BB_FEATURE_SIMPLE_PING |
| 900 | const char ping_usage[] = |
| 901 | "ping host\n" |
| 902 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 903 | "\nSend ICMP ECHO_REQUEST packets to network hosts\n" |
| 904 | #endif |
| 905 | ; |
| 906 | #else /* ! defined BB_FEATURE_SIMPLE_PING */ |
| 907 | const char ping_usage[] = |
| 908 | "ping [OPTION]... host\n" |
| 909 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 910 | "\nSend ICMP ECHO_REQUEST packets to network hosts.\n\n" |
| 911 | "Options:\n" |
| 912 | "\t-c COUNT\tSend only COUNT pings.\n" |
| 913 | "\t-s SIZE\t\tSend SIZE data bytes in packets (default=56).\n" |
| 914 | "\t-q\t\tQuiet mode, only displays output at start\n" |
| 915 | "\t\t\tand when finished.\n" |
| 916 | #endif |
| 917 | ; |
| 918 | #endif |
| 919 | #endif |
| 920 | |
Matt Kraai | 2f46b66 | 2000-07-19 18:01:00 +0000 | [diff] [blame] | 921 | #if defined BB_POWEROFF |
| 922 | const char poweroff_usage[] = |
| 923 | "poweroff\n" |
| 924 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 925 | "\nHalt the system and request that the kernel shut off the power.\n" |
| 926 | #endif |
| 927 | ; |
| 928 | #endif |
| 929 | |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 930 | #if defined BB_PRINTF |
| 931 | const char printf_usage[] = |
| 932 | "printf FORMAT [ARGUMENT...]\n" |
| 933 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 934 | "\nFormats and prints ARGUMENT(s) according to FORMAT,\n" |
| 935 | "Where FORMAT controls the output exactly as in C printf.\n" |
| 936 | #endif |
| 937 | ; |
| 938 | #endif |
| 939 | |
| 940 | #if defined BB_PS |
| 941 | const char ps_usage[] = |
| 942 | "ps\n" |
| 943 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 944 | "\nReport process status\n" |
| 945 | "\nThis version of ps accepts no options.\n" |
| 946 | #endif |
| 947 | ; |
| 948 | #endif |
| 949 | |
Matt Kraai | 2f46b66 | 2000-07-19 18:01:00 +0000 | [diff] [blame] | 950 | #if defined BB_PWD |
| 951 | const char pwd_usage[] = |
| 952 | "pwd\n" |
| 953 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 954 | "\nPrint the full filename of the current working directory.\n" |
| 955 | #endif |
| 956 | ; |
| 957 | #endif |
| 958 | |
Eric Andersen | 918507e | 2000-08-21 22:46:33 +0000 | [diff] [blame] | 959 | #if defined BB_RDATE |
| 960 | const char rdate_usage[] = |
| 961 | "rdate [OPTION] HOST\n" |
| 962 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 963 | "\nGet and possibly set the system date and time from a remote HOST.\n" |
| 964 | "Options:\n" |
| 965 | "\t-s\tSet the system date and time (default).\n" |
| 966 | "\t-p\tPrint the date and time.\n" |
| 967 | #endif |
| 968 | ; |
| 969 | #endif |
| 970 | |
Mark Whitley | 872138d | 2000-10-09 18:56:47 +0000 | [diff] [blame] | 971 | #if defined BB_READLINK |
| 972 | const char readlink_usage[] = |
| 973 | "readlink\n" |
| 974 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 975 | "\nRead a symbolic link.\n" |
| 976 | #endif |
| 977 | ; |
| 978 | #endif |
| 979 | |
Matt Kraai | 2f46b66 | 2000-07-19 18:01:00 +0000 | [diff] [blame] | 980 | #if defined BB_REBOOT |
| 981 | const char reboot_usage[] = |
| 982 | "reboot\n" |
| 983 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 984 | "\nReboot the system.\n" |
| 985 | #endif |
| 986 | ; |
| 987 | #endif |
Eric Andersen | bf960f5 | 2000-07-21 21:32:12 +0000 | [diff] [blame] | 988 | |
| 989 | #if defined BB_RENICE |
| 990 | const char renice_usage[] = |
| 991 | "renice priority pid [pid ...]\n" |
| 992 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 993 | "\nChanges priority of running processes. Allowed priorities range\n" |
| 994 | "from 20 (the process runs only when nothing else is running) to 0\n" |
| 995 | "(default priority) to -20 (almost nothing else ever gets to run).\n" |
| 996 | #endif |
| 997 | ; |
| 998 | #endif |
| 999 | |
Eric Andersen | fa405d0 | 2000-08-21 21:18:52 +0000 | [diff] [blame] | 1000 | |
| 1001 | #if defined BB_RESET |
| 1002 | const char reset_usage[] = |
| 1003 | "reset\n" |
| 1004 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1005 | "\nResets the screen.\n" |
| 1006 | #endif |
| 1007 | ; |
| 1008 | #endif |
| 1009 | |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1010 | #if defined BB_RM |
| 1011 | const char rm_usage[] = |
| 1012 | "rm [OPTION]... FILE...\n" |
| 1013 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1014 | "\nRemove (unlink) the FILE(s). You may use '--' to\n" |
| 1015 | "indicate that all following arguments are non-options.\n\n" |
| 1016 | "Options:\n" |
| 1017 | "\t-f\t\tremove existing destinations, never prompt\n" |
| 1018 | "\t-r or -R\tremove the contents of directories recursively\n" |
| 1019 | #endif |
| 1020 | ; |
| 1021 | #endif |
| 1022 | |
| 1023 | #if defined BB_RMDIR |
| 1024 | const char rmdir_usage[] = |
| 1025 | "rmdir [OPTION]... DIRECTORY...\n" |
| 1026 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1027 | "\nRemove the DIRECTORY(ies), if they are empty.\n" |
| 1028 | #endif |
| 1029 | ; |
| 1030 | #endif |
| 1031 | |
| 1032 | #if defined BB_RMMOD |
| 1033 | const char rmmod_usage[] = |
| 1034 | "rmmod [OPTION]... [MODULE]...\n" |
| 1035 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1036 | "\nUnloads the specified kernel modules from the kernel.\n\n" |
| 1037 | "Options:\n" |
| 1038 | "\t-a\tTry to remove all unused kernel modules.\n" |
| 1039 | #endif |
| 1040 | ; |
| 1041 | #endif |
| 1042 | |
| 1043 | #if defined BB_SED |
| 1044 | const char sed_usage[] = |
| 1045 | "sed [-Vhnef] pattern [files...]\n" |
| 1046 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1047 | "\n" |
Eric Andersen | 4d5ac2f | 2000-08-25 00:23:36 +0000 | [diff] [blame] | 1048 | "-n\t\tsuppress automatic printing of pattern space\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1049 | "-e script\tadd the script to the commands to be executed\n" |
| 1050 | "-f scriptfile\tadd the contents of script-file to the commands to be executed\n" |
Eric Andersen | 4d5ac2f | 2000-08-25 00:23:36 +0000 | [diff] [blame] | 1051 | "-h\t\tdisplay this help message\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1052 | "\n" |
| 1053 | "If no -e or -f is given, the first non-option argument is taken as the\n" |
| 1054 | "sed script to interpret. All remaining arguments are names of input\n" |
| 1055 | "files; if no input files are specified, then the standard input is read.\n" |
| 1056 | #endif |
| 1057 | ; |
| 1058 | #endif |
| 1059 | |
| 1060 | #if defined BB_SETKEYCODES |
| 1061 | const char setkeycodes_usage[] = |
| 1062 | "setkeycodes SCANCODE KEYCODE ...\n" |
| 1063 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1064 | "\nSet entries into the kernel's scancode-to-keycode map,\n" |
| 1065 | "allowing unusual keyboards to generate usable keycodes.\n\n" |
| 1066 | "SCANCODE may be either xx or e0xx (hexadecimal),\n" |
| 1067 | "and KEYCODE is given in decimal\n" |
| 1068 | #endif |
| 1069 | ; |
| 1070 | #endif |
| 1071 | |
| 1072 | #if defined BB_SH |
| 1073 | const char shell_usage[] = |
| 1074 | "sh [FILE]...\n" |
| 1075 | " or: sh -c command [args]...\n" |
| 1076 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1077 | "\nlash: The BusyBox command interpreter (shell).\n\n" |
| 1078 | #endif |
| 1079 | ; |
| 1080 | #endif |
| 1081 | |
| 1082 | #if defined BB_SLEEP |
| 1083 | const char sleep_usage[] = |
| 1084 | "sleep N\n" |
| 1085 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1086 | "\nPause for N seconds.\n" |
| 1087 | #endif |
| 1088 | ; |
| 1089 | #endif |
| 1090 | |
| 1091 | #if defined BB_SORT |
| 1092 | const char sort_usage[] = |
| 1093 | "sort [-n]" |
| 1094 | #ifdef BB_FEATURE_SORT_REVERSE |
| 1095 | " [-r]" |
| 1096 | #endif |
| 1097 | " [FILE]...\n" |
| 1098 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1099 | "\nSorts lines of text in the specified files\n" |
| 1100 | #endif |
| 1101 | ; |
| 1102 | #endif |
| 1103 | |
| 1104 | #if defined BB_SWAPONOFF |
| 1105 | const char swapoff_usage[] = |
| 1106 | "swapoff [OPTION] [device]\n" |
| 1107 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1108 | "\nStop swapping virtual memory pages on the given device.\n\n" |
| 1109 | "Options:\n" |
| 1110 | "\t-a\tStop swapping on all swap devices\n" |
| 1111 | #endif |
| 1112 | ; |
| 1113 | #endif |
| 1114 | |
| 1115 | #if defined BB_SWAPONOFF |
| 1116 | const char swapon_usage[] = |
| 1117 | "swapon [OPTION] [device]\n" |
| 1118 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1119 | "\nStart swapping virtual memory pages on the given device.\n\n" |
| 1120 | "Options:\n" |
| 1121 | "\t-a\tStart swapping on all swap devices\n" |
| 1122 | #endif |
| 1123 | ; |
| 1124 | #endif |
| 1125 | |
| 1126 | #if defined BB_SYNC |
| 1127 | const char sync_usage[] = |
| 1128 | "sync\n" |
| 1129 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1130 | "\nWrite all buffered filesystem blocks to disk.\n" |
| 1131 | #endif |
| 1132 | ; |
| 1133 | #endif |
| 1134 | |
| 1135 | #if defined BB_SYSLOGD |
| 1136 | const char syslogd_usage[] = |
| 1137 | "syslogd [OPTION]...\n" |
| 1138 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1139 | "\nLinux system and kernel (provides klogd) logging utility.\n" |
| 1140 | "Note that this version of syslogd/klogd ignores /etc/syslog.conf.\n\n" |
| 1141 | "Options:\n" |
| 1142 | "\t-m NUM\t\tInterval between MARK lines (default=20min, 0=off)\n" |
| 1143 | "\t-n\t\tRun as a foreground process\n" |
| 1144 | #ifdef BB_FEATURE_KLOGD |
| 1145 | "\t-K\t\tDo not start up the klogd process\n" |
| 1146 | #endif |
| 1147 | "\t-O FILE\t\tUse an alternate log file (default=/var/log/messages)\n" |
Eric Andersen | ced2cef | 2000-07-20 23:41:24 +0000 | [diff] [blame] | 1148 | #ifdef BB_FEATURE_REMOTE_LOG |
| 1149 | "\t-R HOST[:PORT]\t\tLog remotely to IP or hostname on PORT (default PORT=514/UDP)\n" |
| 1150 | #endif |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1151 | #endif |
| 1152 | ; |
| 1153 | #endif |
| 1154 | |
| 1155 | #if defined BB_TAIL |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1156 | const char tail_usage[] = |
| 1157 | "tail [OPTION] [FILE]...\n" |
| 1158 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1159 | "\nPrint last 10 lines of each FILE to standard output.\n" |
| 1160 | "With more than one FILE, precede each with a header giving the\n" |
| 1161 | "file name. With no FILE, or when FILE is -, read standard input.\n\n" |
| 1162 | "Options:\n" |
Eric Andersen | d5fa3e3 | 2000-08-02 16:42:58 +0000 | [diff] [blame] | 1163 | #ifndef BB_FEATURE_SIMPLE_TAIL |
| 1164 | "\t-c=N[kbm]\toutput the last N bytes\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1165 | #endif |
Eric Andersen | d5fa3e3 | 2000-08-02 16:42:58 +0000 | [diff] [blame] | 1166 | "\t-n NUM\t\tPrint last NUM lines instead of first 10\n" |
| 1167 | "\t\t\tAlso can be -NUM or +NUM.\n" |
| 1168 | "\t-f\t\tOutput data as the file grows.\n" |
| 1169 | #ifndef BB_FEATURE_SIMPLE_TAIL |
| 1170 | "\t-q\t\tnever output headers giving file names\n" |
| 1171 | "\t-s SEC\t\tWait SEC seconds between reads with -f\n" |
| 1172 | "\t-v\t\talways output headers giving file names\n\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1173 | "If the first character of N (bytes or lines) is a `+', output begins with \n" |
| 1174 | "the Nth item from the start of each file, otherwise, print the last N items\n" |
Eric Andersen | d5fa3e3 | 2000-08-02 16:42:58 +0000 | [diff] [blame] | 1175 | "in the file. N bytes may be suffixed by k (x1024), b (x512), or m (1024^2).\n" |
| 1176 | //#else |
| 1177 | // "\nIf the first character of N (bytes or lines) is a `+', output begins with \n" |
| 1178 | // "the Nth item from the start of each file.\n" |
| 1179 | #endif |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1180 | #endif |
| 1181 | ; |
| 1182 | #endif |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1183 | |
| 1184 | #if defined BB_TAR |
| 1185 | const char tar_usage[] = |
| 1186 | #ifdef BB_FEATURE_TAR_CREATE |
| 1187 | "tar -[cxtvO] " |
| 1188 | #else |
| 1189 | "tar -[xtvO] " |
| 1190 | #endif |
| 1191 | #if defined BB_FEATURE_TAR_EXCLUDE |
Eric Andersen | fdd5103 | 2000-08-02 18:48:26 +0000 | [diff] [blame] | 1192 | "[--exclude File] " |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1193 | #endif |
Eric Andersen | d5fa3e3 | 2000-08-02 16:42:58 +0000 | [diff] [blame] | 1194 | "[-f tarFile] [FILE(s)] ...\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1195 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1196 | "\nCreate, extract, or list files from a tar file. Note that\n" |
| 1197 | "this version of tar treats hard links as separate files.\n\n" |
| 1198 | "Main operation mode:\n" |
| 1199 | #ifdef BB_FEATURE_TAR_CREATE |
| 1200 | "\tc\t\tcreate\n" |
| 1201 | #endif |
| 1202 | "\tx\t\textract\n" |
| 1203 | "\tt\t\tlist\n" |
| 1204 | "\nFile selection:\n" |
| 1205 | "\tf\t\tname of tarfile or \"-\" for stdin\n" |
| 1206 | "\tO\t\textract to stdout\n" |
| 1207 | #if defined BB_FEATURE_TAR_EXCLUDE |
Eric Andersen | fdd5103 | 2000-08-02 18:48:26 +0000 | [diff] [blame] | 1208 | "\texclude\t\tfile to exclude\n" |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1209 | #endif |
| 1210 | "\nInformative output:\n" |
| 1211 | "\tv\t\tverbosely list files processed\n" |
| 1212 | #endif |
| 1213 | ; |
| 1214 | #endif |
| 1215 | |
| 1216 | #if defined BB_TEE |
| 1217 | const char tee_usage[] = |
| 1218 | "tee [OPTION]... [FILE]...\n" |
| 1219 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1220 | "\nCopy standard input to each FILE, and also to standard output.\n\n" |
| 1221 | "Options:\n" "\t-a\tappend to the given FILEs, do not overwrite\n" |
| 1222 | #endif |
| 1223 | ; |
| 1224 | #endif |
| 1225 | |
| 1226 | #if defined BB_TELNET |
| 1227 | const char telnet_usage[] = |
| 1228 | "telnet host [port]\n" |
| 1229 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1230 | "\nTelnet is used to establish interactive communication with another\n" |
| 1231 | "computer over a network using the TELNET protocol.\n" |
| 1232 | #endif |
| 1233 | ; |
| 1234 | #endif |
| 1235 | |
| 1236 | #if defined BB_TEST |
| 1237 | const char test_usage[] = |
| 1238 | "test EXPRESSION\n" |
| 1239 | "or [ EXPRESSION ]\n" |
| 1240 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1241 | "\nChecks file types and compares values returning an exit\n" |
| 1242 | "code determined by the value of EXPRESSION.\n" |
| 1243 | #endif |
| 1244 | ; |
| 1245 | #endif |
| 1246 | |
| 1247 | #if defined BB_TOUCH |
| 1248 | const char touch_usage[] = |
| 1249 | "touch [-c] file [file ...]\n" |
| 1250 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1251 | "\nUpdate the last-modified date on the given file[s].\n\n" |
| 1252 | "Options:\n" |
| 1253 | "\t-c\tDo not create any files\n" |
| 1254 | #endif |
| 1255 | ; |
| 1256 | #endif |
| 1257 | |
| 1258 | #if defined BB_TR |
| 1259 | const char tr_usage[] = |
| 1260 | "tr [-cds] STRING1 [STRING2]\n" |
| 1261 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1262 | "\nTranslate, squeeze, and/or delete characters from\n" |
| 1263 | "standard input, writing to standard output.\n\n" |
| 1264 | "Options:\n" |
| 1265 | "\t-c\ttake complement of STRING1\n" |
| 1266 | "\t-d\tdelete input characters coded STRING1\n" |
| 1267 | "\t-s\tsqueeze multiple output characters of STRING2 into one character\n" |
| 1268 | #endif |
| 1269 | ; |
| 1270 | #endif |
| 1271 | |
Matt Kraai | 2f46b66 | 2000-07-19 18:01:00 +0000 | [diff] [blame] | 1272 | #if defined BB_TRUE_FALSE |
| 1273 | const char true_usage[] = |
| 1274 | "true\n" |
| 1275 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1276 | "\nReturn an exit code of TRUE (0).\n" |
| 1277 | #endif |
| 1278 | ; |
| 1279 | #endif |
| 1280 | |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1281 | #if defined BB_TTY |
| 1282 | const char tty_usage[] = |
| 1283 | "tty\n" |
| 1284 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1285 | "\nPrint the file name of the terminal connected to standard input.\n\n" |
| 1286 | "Options:\n" |
| 1287 | "\t-s\tprint nothing, only return an exit status\n" |
| 1288 | #endif |
| 1289 | ; |
| 1290 | #endif |
| 1291 | |
| 1292 | #if defined BB_UMOUNT |
| 1293 | const char umount_usage[] = |
| 1294 | "umount [flags] filesystem|directory\n" |
| 1295 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1296 | "Unmount file systems\n" |
| 1297 | "\nFlags:\n" "\t-a:\tUnmount all file systems" |
| 1298 | #ifdef BB_MTAB |
| 1299 | " in /etc/mtab\n\t-n:\tDon't erase /etc/mtab entries\n" |
| 1300 | #else |
| 1301 | "\n" |
| 1302 | #endif |
| 1303 | "\t-r:\tTry to remount devices as read-only if mount is busy\n" |
| 1304 | #if defined BB_FEATURE_MOUNT_FORCE |
| 1305 | "\t-f:\tForce filesystem umount (i.e. unreachable NFS server)\n" |
| 1306 | #endif |
| 1307 | #if defined BB_FEATURE_MOUNT_LOOP |
| 1308 | "\t-l:\tDo not free loop device (if a loop device has been used)\n" |
| 1309 | #endif |
| 1310 | #endif |
| 1311 | ; |
| 1312 | #endif |
| 1313 | |
| 1314 | #if defined BB_UNAME |
| 1315 | const char uname_usage[] = |
| 1316 | "uname [OPTION]...\n" |
| 1317 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1318 | "\nPrint certain system information. With no OPTION, same as -s.\n\n" |
| 1319 | "Options:\n" |
| 1320 | "\t-a\tprint all information\n" |
| 1321 | "\t-m\tthe machine (hardware) type\n" |
| 1322 | "\t-n\tprint the machine's network node hostname\n" |
| 1323 | "\t-r\tprint the operating system release\n" |
| 1324 | "\t-s\tprint the operating system name\n" |
| 1325 | |
| 1326 | "\t-p\tprint the host processor type\n" |
| 1327 | "\t-v\tprint the operating system version\n" |
| 1328 | #endif |
| 1329 | ; |
| 1330 | #endif |
| 1331 | |
| 1332 | #if defined BB_UNIQ |
| 1333 | const char uniq_usage[] = |
| 1334 | "uniq [OPTION]... [INPUT [OUTPUT]]\n" |
| 1335 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1336 | "\nDiscard all but one of successive identical lines from INPUT\n" |
| 1337 | "(or standard input), writing to OUTPUT (or standard output).\n" |
| 1338 | #endif |
| 1339 | ; |
| 1340 | #endif |
| 1341 | |
Eric Andersen | cff3fe3 | 2000-09-20 19:22:26 +0000 | [diff] [blame] | 1342 | #if defined BB_UNIX2DOS |
| 1343 | const char unix2dos_usage[] = |
| 1344 | "unix2dos < unixfile > dosfile\n" |
| 1345 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1346 | "\nConverts a text file from unix format to dos format.\n" |
| 1347 | #endif |
| 1348 | ; |
| 1349 | #endif |
| 1350 | |
| 1351 | #if defined BB_UNRPM |
| 1352 | const char unrpm_usage[] = |
| 1353 | "unrpm < package.rpm | gzip -d | cpio -idmuv\n" |
| 1354 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1355 | "\nExtracts an rpm archive.\n" |
| 1356 | #endif |
| 1357 | ; |
| 1358 | #endif |
| 1359 | |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1360 | #if defined BB_UPDATE |
| 1361 | const char update_usage[] = |
| 1362 | "update [options]\n" |
| 1363 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1364 | "\nPeriodically flushes filesystem buffers.\n\n" |
| 1365 | "Options:\n" |
| 1366 | "\t-S\tforce use of sync(2) instead of flushing\n" |
| 1367 | "\t-s SECS\tcall sync this often (default 30)\n" |
| 1368 | "\t-f SECS\tflush some buffers this often (default 5)\n" |
| 1369 | #endif |
| 1370 | ; |
| 1371 | #endif |
| 1372 | |
Matt Kraai | 2f46b66 | 2000-07-19 18:01:00 +0000 | [diff] [blame] | 1373 | #if defined BB_UPTIME |
| 1374 | const char uptime_usage[] = |
| 1375 | "uptime\n" |
| 1376 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1377 | "\nDisplay the time since the last boot.\n" |
| 1378 | #endif |
| 1379 | ; |
| 1380 | #endif |
| 1381 | |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1382 | #if defined BB_USLEEP |
| 1383 | const char usleep_usage[] = |
| 1384 | "usleep N\n" |
| 1385 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1386 | "\nPause for N microseconds.\n" |
| 1387 | #endif |
| 1388 | ; |
| 1389 | #endif |
| 1390 | |
| 1391 | #if defined BB_UUDECODE |
| 1392 | const char uudecode_usage[] = |
| 1393 | "uudecode [FILE]...\n" |
| 1394 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1395 | "\nUudecode a file that is uuencoded.\n\n" |
| 1396 | "Options:\n" |
| 1397 | "\t-o FILE\tdirect output to FILE\n" |
| 1398 | #endif |
| 1399 | ; |
| 1400 | #endif |
| 1401 | |
| 1402 | #if defined BB_UUENCODE |
| 1403 | const char uuencode_usage[] = |
| 1404 | "uuencode [OPTION] [INFILE] REMOTEFILE\n" |
| 1405 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1406 | "\nUuencode a file.\n\n" |
| 1407 | "Options:\n" |
| 1408 | "\t-m\tuse base64 encoding as of RFC1521\n" |
| 1409 | #endif |
| 1410 | ; |
| 1411 | #endif |
| 1412 | |
| 1413 | #if defined BB_WC |
| 1414 | const char wc_usage[] = |
| 1415 | "wc [OPTION]... [FILE]...\n" |
| 1416 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1417 | "\nPrint line, word, and byte counts for each FILE, and a total line if\n" |
| 1418 | "more than one FILE is specified. With no FILE, read standard input.\n\n" |
| 1419 | "Options:\n" |
| 1420 | "\t-c\tprint the byte counts\n" |
| 1421 | "\t-l\tprint the newline counts\n" |
| 1422 | |
| 1423 | "\t-L\tprint the length of the longest line\n" |
| 1424 | "\t-w\tprint the word counts\n" |
| 1425 | #endif |
| 1426 | ; |
| 1427 | #endif |
| 1428 | |
Eric Andersen | 61a9d8d | 2000-09-04 15:16:51 +0000 | [diff] [blame] | 1429 | #if defined BB_WGET |
| 1430 | const char wget_usage[] = "wget [-c] [-O file] url\n" |
| 1431 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1432 | "\nwget retrieves files via HTTP\n\n" |
| 1433 | "Options:\n" |
| 1434 | "\t-c\tcontinue retrieval of aborted transfers\n" |
| 1435 | "\t-O\tsave to filename ('-' for stdout)\n" |
| 1436 | #endif |
| 1437 | ; |
| 1438 | #endif |
| 1439 | |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1440 | #if defined BB_WHICH |
| 1441 | const char which_usage[] = |
| 1442 | "which [COMMAND ...]\n" |
| 1443 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1444 | "\nLocates a COMMAND.\n" |
| 1445 | #endif |
| 1446 | ; |
| 1447 | #endif |
| 1448 | |
| 1449 | #if defined BB_WHOAMI |
| 1450 | const char whoami_usage[] = |
| 1451 | "whoami\n" |
| 1452 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1453 | "\nPrints the user name associated with the current effective user id.\n" |
| 1454 | #endif |
| 1455 | ; |
| 1456 | #endif |
| 1457 | |
Eric Andersen | 92a61c1 | 2000-09-22 20:01:23 +0000 | [diff] [blame] | 1458 | #if defined BB_XARGS |
Eric Andersen | 5b17693 | 2000-09-22 20:22:28 +0000 | [diff] [blame] | 1459 | const char xargs_usage[] = "xargs [OPTIONS] [COMMAND] [ARGS...]\n" |
| 1460 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1461 | "\nExecutes COMMAND on every item given by standard input.\n\n" |
| 1462 | "Options:\n" |
| 1463 | "\t-t\tPrint the command just before it is run\n" |
Eric Andersen | 5b17693 | 2000-09-22 20:22:28 +0000 | [diff] [blame] | 1464 | #endif |
| 1465 | ; |
Eric Andersen | 92a61c1 | 2000-09-22 20:01:23 +0000 | [diff] [blame] | 1466 | #endif |
| 1467 | |
Matt Kraai | bf181b9 | 2000-07-16 20:57:15 +0000 | [diff] [blame] | 1468 | #if defined BB_YES |
| 1469 | const char yes_usage[] = |
| 1470 | "yes [OPTION]... [STRING]...\n" |
| 1471 | #ifndef BB_FEATURE_TRIVIAL_HELP |
| 1472 | "\nRepeatedly outputs a line with all specified STRING(s), or `y'.\n" |
| 1473 | #endif |
| 1474 | ; |
| 1475 | #endif |