aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Beppu <beppu@lbox.org>2001-03-15 21:08:01 +0000
committerJohn Beppu <beppu@lbox.org>2001-03-15 21:08:01 +0000
commite708cb5f9a74d8243ba3a223395466951255badc (patch)
treebab7fbe2ba6c217c838e88df0ef1d51becd71018
parenta4edd0e946f47dfca4fe0d5ed410743bdcda131c (diff)
downloadbusybox-w32-e708cb5f9a74d8243ba3a223395466951255badc.tar.gz
busybox-w32-e708cb5f9a74d8243ba3a223395466951255badc.tar.bz2
busybox-w32-e708cb5f9a74d8243ba3a223395466951255badc.zip
- generated middle section of busybox.pod w/ autodocifier.pl
- updated autodocifier.pl to use tab to indent example section
-rwxr-xr-xdocs/autodocifier.pl13
-rw-r--r--docs/busybox.pod762
2 files changed, 357 insertions, 418 deletions
diff --git a/docs/autodocifier.pl b/docs/autodocifier.pl
index 7c3aa50bc..567b10310 100755
--- a/docs/autodocifier.pl
+++ b/docs/autodocifier.pl
@@ -69,13 +69,12 @@ sub pod_for_usage {
69 69
70 # prepare example if one exists 70 # prepare example if one exists
71 my $example = (defined $usage->{example}) 71 my $example = (defined $usage->{example})
72 ? $usage->{example} 72 ?
73 "Example:\n\n" .
74 join ("\n",
75 map { "\t$_" }
76 split("\n", $usage->{example})) . "\n\n"
73 : ""; 77 : "";
74 $example =
75 "Example:\n\n" .
76 join ("\n",
77 map { " $_" }
78 split("\n", $example)) . "\n\n";
79 78
80 return 79 return
81 "=item I<$name>". 80 "=item I<$name>".
@@ -227,4 +226,4 @@ John BEPPU <beppu@lineo.com>
227 226
228=cut 227=cut
229 228
230# $Id: autodocifier.pl,v 1.16 2001/03/15 20:49:25 beppu Exp $ 229# $Id: autodocifier.pl,v 1.17 2001/03/15 21:08:01 beppu Exp $
diff --git a/docs/busybox.pod b/docs/busybox.pod
index d7786dd22..c5d7396fc 100644
--- a/docs/busybox.pod
+++ b/docs/busybox.pod
@@ -68,11 +68,8 @@ swapoff, swapon, sync, syslogd, tail, tar, tee, telnet, test, tftp, touch, tr,
68true, tty, umount, uname, uniq, unix2dos, update, uptime, usleep, uudecode, 68true, tty, umount, uname, uniq, unix2dos, update, uptime, usleep, uudecode,
69uuencode, watchdog, wc, wget, which, whoami, xargs, yes, zcat, [ 69uuencode, watchdog, wc, wget, which, whoami, xargs, yes, zcat, [
70 70
71-------------------------------
72
73=over 4 71=over 4
74 72
75
76=item I<ar> 73=item I<ar>
77 74
78ar -[ovR]{ptx} archive filenames 75ar -[ovR]{ptx} archive filenames
@@ -99,12 +96,12 @@ If specified, also removes any trailing SUFFIX.
99 96
100Example: 97Example:
101 98
102$ basename /usr/local/bin/foo 99 $ basename /usr/local/bin/foo
103foo 100 foo
104$ basename /usr/local/bin/ 101 $ basename /usr/local/bin/
105bin 102 bin
106$ basename /foo/bar.txt .txt 103 $ basename /foo/bar.txt .txt
107bar 104 bar
108 105
109------------------------------- 106-------------------------------
110 107
@@ -116,8 +113,8 @@ Concatenates FILE(s) and prints them to stdout.
116 113
117Example: 114Example:
118 115
119$ cat /proc/uptime 116 $ cat /proc/uptime
120110716.72 17.67 117 110716.72 17.67
121 118
122------------------------------- 119-------------------------------
123 120
@@ -133,12 +130,11 @@ Options:
133 130
134Example: 131Example:
135 132
136$ ls -l /tmp/foo 133 $ ls -l /tmp/foo
137-r--r--r-- 1 andersen andersen 0 Apr 12 18:25 /tmp/foo 134 -r--r--r-- 1 andersen andersen 0 Apr 12 18:25 /tmp/foo
138$ chgrp root /tmp/foo 135 $ chgrp root /tmp/foo
139$ ls -l /tmp/foo 136 $ ls -l /tmp/foo
140-r--r--r-- 1 andersen root 0 Apr 12 18:25 /tmp/foo 137 -r--r--r-- 1 andersen root 0 Apr 12 18:25 /tmp/foo
141
142 138
143------------------------------- 139-------------------------------
144 140
@@ -155,15 +151,14 @@ Options:
155 151
156Example: 152Example:
157 153
158$ ls -l /tmp/foo 154 $ ls -l /tmp/foo
159-rw-rw-r-- 1 root root 0 Apr 12 18:25 /tmp/foo 155 -rw-rw-r-- 1 root root 0 Apr 12 18:25 /tmp/foo
160$ chmod u+x /tmp/foo 156 $ chmod u+x /tmp/foo
161$ ls -l /tmp/foo 157 $ ls -l /tmp/foo
162-rwxrw-r-- 1 root root 0 Apr 12 18:25 /tmp/foo* 158 -rwxrw-r-- 1 root root 0 Apr 12 18:25 /tmp/foo*
163$ chmod 444 /tmp/foo 159 $ chmod 444 /tmp/foo
164$ ls -l /tmp/foo 160 $ ls -l /tmp/foo
165-r--r--r-- 1 root root 0 Apr 12 18:25 /tmp/foo 161 -r--r--r-- 1 root root 0 Apr 12 18:25 /tmp/foo
166
167 162
168------------------------------- 163-------------------------------
169 164
@@ -179,15 +174,14 @@ Options:
179 174
180Example: 175Example:
181 176
182$ ls -l /tmp/foo 177 $ ls -l /tmp/foo
183-r--r--r-- 1 andersen andersen 0 Apr 12 18:25 /tmp/foo 178 -r--r--r-- 1 andersen andersen 0 Apr 12 18:25 /tmp/foo
184$ chown root /tmp/foo 179 $ chown root /tmp/foo
185$ ls -l /tmp/foo 180 $ ls -l /tmp/foo
186-r--r--r-- 1 root andersen 0 Apr 12 18:25 /tmp/foo 181 -r--r--r-- 1 root andersen 0 Apr 12 18:25 /tmp/foo
187$ chown root.root /tmp/foo 182 $ chown root.root /tmp/foo
188ls -l /tmp/foo 183 ls -l /tmp/foo
189-r--r--r-- 1 root root 0 Apr 12 18:25 /tmp/foo 184 -r--r--r-- 1 root root 0 Apr 12 18:25 /tmp/foo
190
191 185
192------------------------------- 186-------------------------------
193 187
@@ -199,13 +193,12 @@ Run COMMAND with root directory set to NEWROOT.
199 193
200Example: 194Example:
201 195
202$ ls -l /bin/ls 196 $ ls -l /bin/ls
203lrwxrwxrwx 1 root root 12 Apr 13 00:46 /bin/ls -> /BusyBox 197 lrwxrwxrwx 1 root root 12 Apr 13 00:46 /bin/ls -> /BusyBox
204$ mount /dev/hdc1 /mnt -t minix 198 $ mount /dev/hdc1 /mnt -t minix
205$ chroot /mnt 199 $ chroot /mnt
206$ ls -l /bin/ls 200 $ ls -l /bin/ls
207-rwxr-xr-x 1 root root 40816 Feb 5 07:45 /bin/ls* 201 -rwxr-xr-x 1 root root 40816 Feb 5 07:45 /bin/ls*
208
209 202
210------------------------------- 203-------------------------------
211 204
@@ -264,11 +257,10 @@ Options:
264 257
265Example: 258Example:
266 259
267$ echo Hello world | cut -f 1 -d ' ' 260 $ echo Hello world | cut -f 1 -d ' '
268Hello 261 Hello
269$ echo Hello world | cut -f 2 -d ' ' 262 $ echo Hello world | cut -f 2 -d ' '
270world 263 world
271
272 264
273------------------------------- 265-------------------------------
274 266
@@ -287,9 +279,8 @@ Options:
287 279
288Example: 280Example:
289 281
290$ date 282 $ date
291Wed Apr 12 18:52:41 MDT 2000 283 Wed Apr 12 18:52:41 MDT 2000
292
293 284
294------------------------------- 285-------------------------------
295 286
@@ -303,17 +294,16 @@ i.e. 'dc 2 2 add' -> 4, and 'dc 8 8 \* 2 2 + /' -> 16
303 294
304Example: 295Example:
305 296
306$ dc 2 2 + 297 $ dc 2 2 +
3074 298 4
308$ dc 8 8 * 2 2 + / 299 $ dc 8 8 * 2 2 + /
30916 300 16
310$ dc 0 1 and 301 $ dc 0 1 and
3110 302 0
312$ dc 0 1 or 303 $ dc 0 1 or
3131 304 1
314$ echo 72 9 div 8 mul | dc 305 $ echo 72 9 div 8 mul | dc
31564 306 64
316
317 307
318------------------------------- 308-------------------------------
319 309
@@ -338,10 +328,9 @@ MD (x1000000), M (x1048576), GD (x1000000000) or G (x1073741824).
338 328
339Example: 329Example:
340 330
341$ dd if=/dev/zero of=/dev/ram1 bs=1M count=4 331 $ dd if=/dev/zero of=/dev/ram1 bs=1M count=4
3424+0 records in 332 4+0 records in
3434+0 records out 333 4+0 records out
344
345 334
346------------------------------- 335-------------------------------
347 336
@@ -367,14 +356,13 @@ Options:
367 356
368Example: 357Example:
369 358
370$ df 359 $ df
371Filesystem 1k-blocks Used Available Use% Mounted on 360 Filesystem 1k-blocks Used Available Use% Mounted on
372/dev/sda3 8690864 8553540 137324 98% / 361 /dev/sda3 8690864 8553540 137324 98% /
373/dev/sda1 64216 36364 27852 57% /boot 362 /dev/sda1 64216 36364 27852 57% /boot
374$ df /dev/sda3 363 $ df /dev/sda3
375Filesystem 1k-blocks Used Available Use% Mounted on 364 Filesystem 1k-blocks Used Available Use% Mounted on
376/dev/sda3 8690864 8553540 137324 98% / 365 /dev/sda3 8690864 8553540 137324 98% /
377
378 366
379------------------------------- 367-------------------------------
380 368
@@ -386,11 +374,10 @@ Strips non-directory suffix from FILENAME
386 374
387Example: 375Example:
388 376
389$ dirname /tmp/foo 377 $ dirname /tmp/foo
390/tmp 378 /tmp
391$ dirname /tmp/foo/ 379 $ dirname /tmp/foo/
392/tmp 380 /tmp
393
394 381
395------------------------------- 382-------------------------------
396 383
@@ -450,8 +437,7 @@ Options:
450 437
451Example: 438Example:
452 439
453$ dpkg-deb -X ./busybox_0.48-1_i386.deb /tmp 440 $ dpkg-deb -X ./busybox_0.48-1_i386.deb /tmp
454
455 441
456------------------------------- 442-------------------------------
457 443
@@ -472,18 +458,17 @@ Options:
472 458
473Example: 459Example:
474 460
475$ du 461 $ du
47616 ./CVS 462 16 ./CVS
47712 ./kernel-patches/CVS 463 12 ./kernel-patches/CVS
47880 ./kernel-patches 464 80 ./kernel-patches
47912 ./tests/CVS 465 12 ./tests/CVS
48036 ./tests 466 36 ./tests
48112 ./scripts/CVS 467 12 ./scripts/CVS
48216 ./scripts 468 16 ./scripts
48312 ./docs/CVS 469 12 ./docs/CVS
484104 ./docs 470 104 ./docs
4852417 . 471 2417 .
486
487 472
488------------------------------- 473-------------------------------
489 474
@@ -495,8 +480,7 @@ Prints out a binary keyboard translation table to standard output.
495 480
496Example: 481Example:
497 482
498$ dumpkmap > keymap 483 $ dumpkmap > keymap
499
500 484
501------------------------------- 485-------------------------------
502 486
@@ -509,15 +493,14 @@ or stdin to stdout. (i.e. 'dutmp /var/run/utmp')
509 493
510Example: 494Example:
511 495
512$ dutmp /var/run/utmp 496 $ dutmp /var/run/utmp
5138|7||si|||0|0|0|955637625|760097|0 497 8|7||si|||0|0|0|955637625|760097|0
5142|0|~|~~|reboot||0|0|0|955637625|782235|0 498 2|0|~|~~|reboot||0|0|0|955637625|782235|0
5151|20020|~|~~|runlevel||0|0|0|955637625|800089|0 499 1|20020|~|~~|runlevel||0|0|0|955637625|800089|0
5168|125||l4|||0|0|0|955637629|998367|0 500 8|125||l4|||0|0|0|955637629|998367|0
5176|245|tty1|1|LOGIN||0|0|0|955637630|998974|0 501 6|245|tty1|1|LOGIN||0|0|0|955637630|998974|0
5186|246|tty2|2|LOGIN||0|0|0|955637630|999498|0 502 6|246|tty2|2|LOGIN||0|0|0|955637630|999498|0
5197|336|pts/0|vt00andersen|andersen|:0.0|0|0|0|955637763|0|0 503 7|336|pts/0|vt00andersen|andersen|:0.0|0|0|0|955637763|0|0
520
521 504
522------------------------------- 505-------------------------------
523 506
@@ -535,29 +518,20 @@ Options:
535 518
536Example: 519Example:
537 520
538$ echo Erik is cool 521 $ echo Erik is cool
539Erik is cool 522 Erik is cool
540$ echo -e Erik 523 $ echo -e Erik
541is 524 is
542cool 525 cool
543Erik 526 Erik
544is 527 is
545cool 528 cool
546$ echo Erik 529 $ echo Erik
547is 530 is
548cool 531 cool
549Erik 532 Erik
550is 533 is
551cool 534 cool
552
553
554-------------------------------
555
556=item I<egrep>
557
558egrep
559
560
561 535
562------------------------------- 536-------------------------------
563 537
@@ -609,10 +583,9 @@ Return an exit code of FALSE (1).
609 583
610Example: 584Example:
611 585
612$ false 586 $ false
613$ echo $? 587 $ echo $?
6141 588 1
615
616 589
617------------------------------- 590-------------------------------
618 591
@@ -624,14 +597,13 @@ Show and modify frame buffer settings
624 597
625Example: 598Example:
626 599
627$ fbset 600 $ fbset
628mode 1024x768-76 601 mode 1024x768-76
629 geometry 1024 768 1024 768 16 602 geometry 1024 768 1024 768 16
630 timings 12714 128 32 16 4 128 4 603 timings 12714 128 32 16 4 128 4
631 accel false 604 accel false
632 rgba 5/11,6/5,5/0,0/0 605 rgba 5/11,6/5,5/0,0/0
633endmode 606 endmode
634
635 607
636------------------------------- 608-------------------------------
637 609
@@ -662,9 +634,8 @@ EXPRESSION may consist of:
662 634
663Example: 635Example:
664 636
665$ find / -name /etc/passwd 637 $ find / -name /etc/passwd
666/etc/passwd 638 /etc/passwd
667
668 639
669------------------------------- 640-------------------------------
670 641
@@ -676,12 +647,12 @@ Displays the amount of free and used system memory
676 647
677Example: 648Example:
678 649
679$ free 650 $ free
680 total used free shared buffers 651 total used free shared buffers
681 Mem: 257628 248724 8904 59644 93124 652 Mem: 257628 248724 8904 59644 93124
682 Swap: 128516 8404 120112 653 Swap: 128516 8404 120112
683Total: 386144 257128 129016 654 Total: 386144 257128 129016
684 655
685 656
686------------------------------- 657-------------------------------
687 658
@@ -693,8 +664,7 @@ Frees all memory used by the specified ramdisk.
693 664
694Example: 665Example:
695 666
696$ freeramdisk /dev/ram2 667 $ freeramdisk /dev/ram2
697
698 668
699------------------------------- 669-------------------------------
700 670
@@ -734,25 +704,24 @@ Parse command options
734 704
735Example: 705Example:
736 706
737$ cat getopt.test 707 $ cat getopt.test
738GETOPT=`getopt -o ab:c:: --long a-long,b-long:,c-long:: \ 708 GETOPT=`getopt -o ab:c:: --long a-long,b-long:,c-long:: \
739 -n 'example.busybox' -- $@` 709 -n 'example.busybox' -- $@`
740if [ $? != 0 ] ; then exit 1 ; fi 710 if [ $? != 0 ] ; then exit 1 ; fi
741eval set -- $GETOPT 711 eval set -- $GETOPT
742while true ; do 712 while true ; do
743 case $1 in 713 case $1 in
744 -a|--a-long) echo Option a ; shift ;; 714 -a|--a-long) echo Option a ; shift ;;
745 -b|--b-long) echo Option b, argument `$2' ; shift 2 ;; 715 -b|--b-long) echo Option b, argument `$2' ; shift 2 ;;
746 -c|--c-long) 716 -c|--c-long)
747 case $2 in 717 case $2 in
748 \) echo Option c, no argument; shift 2 ;; 718 \) echo Option c, no argument; shift 2 ;;
749 *) echo Option c, argument `$2' ; shift 2 ;; 719 *) echo Option c, argument `$2' ; shift 2 ;;
750 esac ;; 720 esac ;;
751 --) shift ; break ;; 721 --) shift ; break ;;
752 *) echo Internal error! ; exit 1 ;; 722 *) echo Internal error! ; exit 1 ;;
753 esac 723 esac
754done 724 done
755
756 725
757------------------------------- 726-------------------------------
758 727
@@ -774,11 +743,10 @@ Options:
774 743
775Example: 744Example:
776 745
777$ grep root /etc/passwd 746 $ grep root /etc/passwd
778root:x:0:0:root:/root:/bin/bash 747 root:x:0:0:root:/root:/bin/bash
779$ grep ^[rR]oo. /etc/passwd 748 $ grep ^[rR]oo. /etc/passwd
780root:x:0:0:root:/root:/bin/bash 749 root:x:0:0:root:/root:/bin/bash
781
782 750
783------------------------------- 751-------------------------------
784 752
@@ -795,12 +763,11 @@ Options:
795 763
796Example: 764Example:
797 765
798$ ls -la /tmp/BusyBox* 766 $ ls -la /tmp/BusyBox*
799-rw-rw-r-- 1 andersen andersen 557009 Apr 11 10:55 /tmp/BusyBox-0.43.tar.gz 767 -rw-rw-r-- 1 andersen andersen 557009 Apr 11 10:55 /tmp/BusyBox-0.43.tar.gz
800$ gunzip /tmp/BusyBox-0.43.tar.gz 768 $ gunzip /tmp/BusyBox-0.43.tar.gz
801$ ls -la /tmp/BusyBox* 769 $ ls -la /tmp/BusyBox*
802-rw-rw-r-- 1 andersen andersen 1761280 Apr 14 17:47 /tmp/BusyBox-0.43.tar 770 -rw-rw-r-- 1 andersen andersen 1761280 Apr 14 17:47 /tmp/BusyBox-0.43.tar
803
804 771
805------------------------------- 772-------------------------------
806 773
@@ -818,12 +785,11 @@ Options:
818 785
819Example: 786Example:
820 787
821$ ls -la /tmp/BusyBox* 788 $ ls -la /tmp/BusyBox*
822-rw-rw-r-- 1 andersen andersen 1761280 Apr 14 17:47 /tmp/BusyBox-0.43.tar 789 -rw-rw-r-- 1 andersen andersen 1761280 Apr 14 17:47 /tmp/BusyBox-0.43.tar
823$ gzip /tmp/BusyBox-0.43.tar 790 $ gzip /tmp/BusyBox-0.43.tar
824$ ls -la /tmp/BusyBox* 791 $ ls -la /tmp/BusyBox*
825-rw-rw-r-- 1 andersen andersen 554058 Apr 14 17:49 /tmp/BusyBox-0.43.tar.gz 792 -rw-rw-r-- 1 andersen andersen 554058 Apr 14 17:49 /tmp/BusyBox-0.43.tar.gz
826
827 793
828------------------------------- 794-------------------------------
829 795
@@ -849,10 +815,9 @@ Options:
849 815
850Example: 816Example:
851 817
852$ head -n 2 /etc/passwd 818 $ head -n 2 /etc/passwd
853root:x:0:0:root:/root:/bin/bash 819 root:x:0:0:root:/root:/bin/bash
854daemon:x:1:1:daemon:/usr/sbin:/bin/sh 820 daemon:x:1:1:daemon:/usr/sbin:/bin/sh
855
856 821
857------------------------------- 822-------------------------------
858 823
@@ -880,9 +845,8 @@ Options:
880 845
881Example: 846Example:
882 847
883$ hostname 848 $ hostname
884slag 849 slag
885
886 850
887------------------------------- 851-------------------------------
888 852
@@ -901,9 +865,8 @@ Options:
901 865
902Example: 866Example:
903 867
904$ id 868 $ id
905uid=1000(andersen) gid=1000(andersen) 869 uid=1000(andersen) gid=1000(andersen)
906
907 870
908------------------------------- 871-------------------------------
909 872
@@ -1056,15 +1019,14 @@ Options:
1056 1019
1057Example: 1020Example:
1058 1021
1059$ ps | grep apache 1022 $ ps | grep apache
1060252 root root S [apache] 1023 252 root root S [apache]
1061263 www-data www-data S [apache] 1024 263 www-data www-data S [apache]
1062264 www-data www-data S [apache] 1025 264 www-data www-data S [apache]
1063265 www-data www-data S [apache] 1026 265 www-data www-data S [apache]
1064266 www-data www-data S [apache] 1027 266 www-data www-data S [apache]
1065267 www-data www-data S [apache] 1028 267 www-data www-data S [apache]
1066$ kill 252 1029 $ kill 252
1067
1068 1030
1069------------------------------- 1031-------------------------------
1070 1032
@@ -1080,8 +1042,8 @@ Options:
1080 1042
1081Example: 1043Example:
1082 1044
1083$ killall apache 1045 $ killall apache
1084 1046
1085 1047
1086------------------------------- 1048-------------------------------
1087 1049
@@ -1104,9 +1066,8 @@ Prints out the length of the specified STRING.
1104 1066
1105Example: 1067Example:
1106 1068
1107$ length Hello 1069 $ length Hello
11085 1070 5
1109
1110 1071
1111------------------------------- 1072-------------------------------
1112 1073
@@ -1126,10 +1087,10 @@ Options:
1126 1087
1127Example: 1088Example:
1128 1089
1129$ ln -s BusyBox /tmp/ls 1090 $ ln -s BusyBox /tmp/ls
1130$ ls -l /tmp/ls 1091 $ ls -l /tmp/ls
1131lrwxrwxrwx 1 root root 7 Apr 12 18:39 ls -> BusyBox* 1092 lrwxrwxrwx 1 root root 7 Apr 12 18:39 ls -> BusyBox*
1132 1093
1133 1094
1134------------------------------- 1095-------------------------------
1135 1096
@@ -1141,8 +1102,8 @@ Loads an acm from standard input.
1141 1102
1142Example: 1103Example:
1143 1104
1144$ loadacm < /etc/i18n/acmname 1105 $ loadacm < /etc/i18n/acmname
1145 1106
1146 1107
1147------------------------------- 1108-------------------------------
1148 1109
@@ -1154,8 +1115,8 @@ Loads a console font from standard input.
1154 1115
1155Example: 1116Example:
1156 1117
1157$ loadfont < /etc/i18n/fontname 1118 $ loadfont < /etc/i18n/fontname
1158 1119
1159 1120
1160------------------------------- 1121-------------------------------
1161 1122
@@ -1167,8 +1128,8 @@ Loads a binary keyboard translation table from standard input.
1167 1128
1168Example: 1129Example:
1169 1130
1170$ loadkmap < /etc/i18n/lang-keymap 1131 $ loadkmap < /etc/i18n/lang-keymap
1171 1132
1172 1133
1173------------------------------- 1134-------------------------------
1174 1135
@@ -1187,8 +1148,8 @@ Options:
1187 1148
1188Example: 1149Example:
1189 1150
1190$ logger hello 1151 $ logger hello
1191 1152
1192 1153
1193------------------------------- 1154-------------------------------
1194 1155
@@ -1200,9 +1161,9 @@ Print the name of the current user.
1200 1161
1201Example: 1162Example:
1202 1163
1203$ logname 1164 $ logname
1204root 1165 root
1205 1166
1206 1167
1207------------------------------- 1168-------------------------------
1208 1169
@@ -1282,11 +1243,11 @@ For example:
1282 1243
1283Example: 1244Example:
1284 1245
1285$ makedevs /dev/ttyS c 4 66 2 63 1246 $ makedevs /dev/ttyS c 4 66 2 63
1286[creates ttyS2-ttyS63] 1247 [creates ttyS2-ttyS63]
1287$ makedevs /dev/hda b 3 0 0 8 s 1248 $ makedevs /dev/hda b 3 0 0 8 s
1288[creates hda,hda1-hda8] 1249 [creates hda,hda1-hda8]
1289 1250
1290 1251
1291------------------------------- 1252-------------------------------
1292 1253
@@ -1312,15 +1273,14 @@ The following two options are useful only when verifying checksums:
1312 1273
1313Example: 1274Example:
1314 1275
1315$ md5sum < busybox 1276 $ md5sum < busybox
13166fd11e98b98a58f64ff3398d7b324003 1277 6fd11e98b98a58f64ff3398d7b324003
1317$ md5sum busybox 1278 $ md5sum busybox
13186fd11e98b98a58f64ff3398d7b324003 busybox 1279 6fd11e98b98a58f64ff3398d7b324003 busybox
1319$ md5sum -c - 1280 $ md5sum -c -
13206fd11e98b98a58f64ff3398d7b324003 busybox 1281 6fd11e98b98a58f64ff3398d7b324003 busybox
1321busybox: OK 1282 busybox: OK
1322^D 1283 ^D
1323
1324 1284
1325------------------------------- 1285-------------------------------
1326 1286
@@ -1337,13 +1297,13 @@ Options:
1337 1297
1338Example: 1298Example:
1339 1299
1340$ mkdir /tmp/foo 1300 $ mkdir /tmp/foo
1341$ mkdir /tmp/foo 1301 $ mkdir /tmp/foo
1342/tmp/foo: File exists 1302 /tmp/foo: File exists
1343$ mkdir /tmp/foo/bar/baz 1303 $ mkdir /tmp/foo/bar/baz
1344/tmp/foo/bar/baz: No such file or directory 1304 /tmp/foo/bar/baz: No such file or directory
1345$ mkdir -p /tmp/foo/bar/baz 1305 $ mkdir -p /tmp/foo/bar/baz
1346 1306
1347 1307
1348------------------------------- 1308-------------------------------
1349 1309
@@ -1393,9 +1353,9 @@ TYPEs include:
1393 1353
1394Example: 1354Example:
1395 1355
1396$ mknod /dev/fd0 b 2 0 1356 $ mknod /dev/fd0 b 2 0
1397$ mknod -m 644 /tmp/pipe p 1357 $ mknod -m 644 /tmp/pipe p
1398 1358
1399 1359
1400------------------------------- 1360-------------------------------
1401 1361
@@ -1424,11 +1384,11 @@ TEMPLATE is any name with six `Xs' (i.e. /tmp/temp.XXXXXX).
1424 1384
1425Example: 1385Example:
1426 1386
1427$ mktemp /tmp/temp.XXXXXX 1387 $ mktemp /tmp/temp.XXXXXX
1428/tmp/temp.mWiLjM 1388 /tmp/temp.mWiLjM
1429$ ls -la /tmp/temp.mWiLjM 1389 $ ls -la /tmp/temp.mWiLjM
1430-rw------- 1 andersen andersen 0 Apr 25 17:10 /tmp/temp.mWiLjM 1390 -rw------- 1 andersen andersen 0 Apr 25 17:10 /tmp/temp.mWiLjM
1431 1391
1432 1392
1433------------------------------- 1393-------------------------------
1434 1394
@@ -1440,8 +1400,8 @@ More is a filter for viewing FILE one screenful at a time.
1440 1400
1441Example: 1401Example:
1442 1402
1443$ dmesg | more 1403 $ dmesg | more
1444 1404
1445 1405
1446------------------------------- 1406-------------------------------
1447 1407
@@ -1477,13 +1437,13 @@ You'll have to see the written documentation for those.
1477 1437
1478Example: 1438Example:
1479 1439
1480$ mount 1440 $ mount
1481/dev/hda3 on / type minix (rw) 1441 /dev/hda3 on / type minix (rw)
1482proc on /proc type proc (rw) 1442 proc on /proc type proc (rw)
1483devpts on /dev/pts type devpts (rw) 1443 devpts on /dev/pts type devpts (rw)
1484$ mount /dev/fd0 /mnt -t msdos -o ro 1444 $ mount /dev/fd0 /mnt -t msdos -o ro
1485$ mount /tmp/diskimage /opt -t ext2 -o loop 1445 $ mount /tmp/diskimage /opt -t ext2 -o loop
1486 1446
1487 1447
1488------------------------------- 1448-------------------------------
1489 1449
@@ -1511,8 +1471,8 @@ Rename SOURCE to DEST, or move SOURCE(s) to DIRECTORY.
1511 1471
1512Example: 1472Example:
1513 1473
1514$ mv /tmp/foo /bin/bar 1474 $ mv /tmp/foo /bin/bar
1515 1475
1516 1476
1517------------------------------- 1477-------------------------------
1518 1478
@@ -1524,14 +1484,14 @@ Netcat opens a pipe to IP:port
1524 1484
1525Example: 1485Example:
1526 1486
1527$ nc foobar.somedomain.com 25 1487 $ nc foobar.somedomain.com 25
1528220 foobar ESMTP Exim 3.12 help 1488 220 foobar ESMTP Exim 3.12 help
1529214-Commands supported: 1489 214-Commands supported:
1530214- HELO EHLO MAIL RCPT DATA AUTH 1490 214- HELO EHLO MAIL RCPT DATA AUTH
1531214 NOOP QUIT RSET HELP 1491 214 NOOP QUIT RSET HELP
1532quit 1492 quit
1533221 foobar closing connection 1493 221 foobar closing connection
1534 1494
1535 1495
1536------------------------------- 1496-------------------------------
1537 1497
@@ -1543,13 +1503,13 @@ Queries the nameserver for the IP address of the given HOST
1543 1503
1544Example: 1504Example:
1545 1505
1546$ nslookup localhost 1506 $ nslookup localhost
1547Server: default 1507 Server: default
1548Address: default 1508 Address: default
1549 1509
1550Name: debian 1510 Name: debian
1551Address: 127.0.0.1 1511 Address: 127.0.0.1
1552 1512
1553 1513
1554------------------------------- 1514-------------------------------
1555 1515
@@ -1568,14 +1528,14 @@ Options:
1568 1528
1569Example: 1529Example:
1570 1530
1571$ ping localhost 1531 $ ping localhost
1572PING slag (127.0.0.1): 56 data bytes 1532 PING slag (127.0.0.1): 56 data bytes
157364 bytes from 127.0.0.1: icmp_seq=0 ttl=255 time=20.1 ms 1533 64 bytes from 127.0.0.1: icmp_seq=0 ttl=255 time=20.1 ms
1574 1534
1575--- debian ping statistics --- 1535 --- debian ping statistics ---
15761 packets transmitted, 1 packets received, 0% packet loss 1536 1 packets transmitted, 1 packets received, 0% packet loss
1577round-trip min/avg/max = 20.1/20.1/20.1 ms 1537 round-trip min/avg/max = 20.1/20.1/20.1 ms
1578 1538
1579 1539
1580------------------------------- 1540-------------------------------
1581 1541
@@ -1605,10 +1565,10 @@ Where FORMAT controls the output exactly as in C printf.
1605 1565
1606Example: 1566Example:
1607 1567
1608$ printf Val=%d 1568 $ printf Val=%d
1609 5 1569 5
1610Val=5 1570 Val=5
1611 1571
1612 1572
1613------------------------------- 1573-------------------------------
1614 1574
@@ -1622,18 +1582,17 @@ This version of ps accepts no options.
1622 1582
1623Example: 1583Example:
1624 1584
1625$ ps 1585 $ ps
1626 PID Uid Gid State Command 1586 PID Uid Gid State Command
1627 1 root root S init 1587 1 root root S init
1628 2 root root S [kflushd] 1588 2 root root S [kflushd]
1629 3 root root S [kupdate] 1589 3 root root S [kupdate]
1630 4 root root S [kpiod] 1590 4 root root S [kpiod]
1631 5 root root S [kswapd] 1591 5 root root S [kswapd]
1632 742 andersen andersen S [bash] 1592 742 andersen andersen S [bash]
1633 743 andersen andersen S -bash 1593 743 andersen andersen S -bash
1634 745 root root S [getty] 1594 745 root root S [getty]
1635 2990 andersen andersen R ps 1595 2990 andersen andersen R ps
1636
1637 1596
1638------------------------------- 1597-------------------------------
1639 1598
@@ -1645,9 +1604,8 @@ Print the full filename of the current working directory.
1645 1604
1646Example: 1605Example:
1647 1606
1648$ pwd 1607 $ pwd
1649/root 1608 /root
1650
1651 1609
1652------------------------------- 1610-------------------------------
1653 1611
@@ -1713,8 +1671,7 @@ Options:
1713 1671
1714Example: 1672Example:
1715 1673
1716$ rm -rf /tmp/foo 1674 $ rm -rf /tmp/foo
1717
1718 1675
1719------------------------------- 1676-------------------------------
1720 1677
@@ -1742,8 +1699,7 @@ Options:
1742 1699
1743Example: 1700Example:
1744 1701
1745$ rmmod tulip 1702 $ rmmod tulip
1746
1747 1703
1748------------------------------- 1704-------------------------------
1749 1705
@@ -1780,9 +1736,8 @@ files; if no input files are specified, then the standard input is read.
1780 1736
1781Example: 1737Example:
1782 1738
1783$ echo foo | sed -e 's/f[a-zA-Z]o/bar/g' 1739 $ echo foo | sed -e 's/f[a-zA-Z]o/bar/g'
1784bar 1740 bar
1785
1786 1741
1787------------------------------- 1742-------------------------------
1788 1743
@@ -1798,8 +1753,7 @@ and KEYCODE is given in decimal
1798 1753
1799Example: 1754Example:
1800 1755
1801$ setkeycodes e030 127 1756 $ setkeycodes e030 127
1802
1803 1757
1804------------------------------- 1758-------------------------------
1805 1759
@@ -1829,9 +1783,8 @@ Pause for N seconds.
1829 1783
1830Example: 1784Example:
1831 1785
1832$ sleep 2 1786 $ sleep 2
1833[2 second delay results] 1787 [2 second delay results]
1834
1835 1788
1836------------------------------- 1789-------------------------------
1837 1790
@@ -1843,19 +1796,18 @@ Sorts lines of text in the specified files
1843 1796
1844Example: 1797Example:
1845 1798
1846$ echo -e e 1799 $ echo -e e
1847f 1800 f
1848b 1801 b
1849d 1802 d
1850c 1803 c
1851a | sort 1804 a | sort
1852a 1805 a
1853b 1806 b
1854c 1807 c
1855d 1808 d
1856e 1809 e
1857f 1810 f
1858
1859 1811
1860------------------------------- 1812-------------------------------
1861 1813
@@ -1924,9 +1876,8 @@ Options:
1924 1876
1925Example: 1877Example:
1926 1878
1927$ syslogd -R masterlog:514 1879 $ syslogd -R masterlog:514
1928$ syslogd -R 192.168.1.1:601 1880 $ syslogd -R 192.168.1.1:601
1929
1930 1881
1931------------------------------- 1882-------------------------------
1932 1883
@@ -1947,15 +1898,14 @@ Options:
1947 -s SEC wait SEC seconds between reads with -f 1898 -s SEC wait SEC seconds between reads with -f
1948 -v always output headers giving file names 1899 -v always output headers giving file names
1949 1900
1950If the first character of N (bytes or lines) is a `+', output begins with 1901If the first character of N (bytes or lines) is a '+', output begins with
1951the Nth item from the start of each file, otherwise, print the last N items 1902the Nth item from the start of each file, otherwise, print the last N items
1952in the file. N bytes may be suffixed by k (x1024), b (x512), or m (1024^2). 1903in the file. N bytes may be suffixed by k (x1024), b (x512), or m (1024^2).
1953 1904
1954Example: 1905Example:
1955 1906
1956$ tail -n 1 /etc/resolv.conf 1907 $ tail -n 1 /etc/resolv.conf
1957nameserver 10.0.0.1 1908 nameserver 10.0.0.1
1958
1959 1909
1960------------------------------- 1910-------------------------------
1961 1911
@@ -1984,9 +1934,8 @@ Informative output:
1984 1934
1985Example: 1935Example:
1986 1936
1987$ zcat /tmp/tarball.tar.gz | tar -xf - 1937 $ zcat /tmp/tarball.tar.gz | tar -xf -
1988$ tar -cf /tmp/tarball.tar /usr/local 1938 $ tar -cf /tmp/tarball.tar /usr/local
1989
1990 1939
1991------------------------------- 1940-------------------------------
1992 1941
@@ -2002,10 +1951,9 @@ Options:
2002 1951
2003Example: 1952Example:
2004 1953
2005$ echo Hello | tee /tmp/foo 1954 $ echo Hello | tee /tmp/foo
2006$ cat /tmp/foo 1955 $ cat /tmp/foo
2007Hello 1956 Hello
2008
2009 1957
2010------------------------------- 1958-------------------------------
2011 1959
@@ -2028,19 +1976,18 @@ code determined by the value of EXPRESSION.
2028 1976
2029Example: 1977Example:
2030 1978
2031$ test 1 -eq 2 1979 $ test 1 -eq 2
2032$ echo $? 1980 $ echo $?
20331 1981 1
2034$ test 1 -eq 1 1982 $ test 1 -eq 1
2035$ echo $? 1983 $ echo $?
20360 1984 0
2037$ [ -d /etc ] 1985 $ [ -d /etc ]
2038$ echo $? 1986 $ echo $?
20390 1987 0
2040$ [ -d /junk ] 1988 $ [ -d /junk ]
2041$ echo $? 1989 $ echo $?
20421 1990 1
2043
2044 1991
2045------------------------------- 1992-------------------------------
2046 1993
@@ -2071,12 +2018,12 @@ Options:
2071 2018
2072Example: 2019Example:
2073 2020
2074$ ls -l /tmp/foo 2021 $ ls -l /tmp/foo
2075/bin/ls: /tmp/foo: No such file or directory 2022 /bin/ls: /tmp/foo: No such file or directory
2076$ touch /tmp/foo 2023 $ touch /tmp/foo
2077$ ls -l /tmp/foo 2024 $ ls -l /tmp/foo
2078-rw-rw-r-- 1 andersen andersen 0 Apr 15 01:11 /tmp/foo 2025 -rw-rw-r-- 1 andersen andersen 0 Apr 15 01:11 /tmp/foo
2079 2026
2080 2027
2081------------------------------- 2028-------------------------------
2082 2029
@@ -2095,9 +2042,9 @@ Options:
2095 2042
2096Example: 2043Example:
2097 2044
2098$ echo gdkkn vnqkc | tr [a-y] [b-z] 2045 $ echo gdkkn vnqkc | tr [a-y] [b-z]
2099hello world 2046 hello world
2100 2047
2101 2048
2102------------------------------- 2049-------------------------------
2103 2050
@@ -2109,10 +2056,9 @@ Return an exit code of TRUE (0).
2109 2056
2110Example: 2057Example:
2111 2058
2112$ true 2059 $ true
2113$ echo $? 2060 $ echo $?
21140 2061 0
2115
2116 2062
2117------------------------------- 2063-------------------------------
2118 2064
@@ -2128,9 +2074,8 @@ Options:
2128 2074
2129Example: 2075Example:
2130 2076
2131$ tty 2077 $ tty
2132/dev/tty2 2078 /dev/tty2
2133
2134 2079
2135------------------------------- 2080-------------------------------
2136 2081
@@ -2150,8 +2095,7 @@ Flags:
2150 2095
2151Example: 2096Example:
2152 2097
2153$ umount /dev/hdc1 2098 $ umount /dev/hdc1
2154
2155 2099
2156------------------------------- 2100-------------------------------
2157 2101
@@ -2173,8 +2117,8 @@ Options:
2173 2117
2174Example: 2118Example:
2175 2119
2176$ uname -a 2120 $ uname -a
2177Linux debian 2.2.15pre13 2121 Linux debian 2.2.15pre13
2178 2122
2179------------------------------- 2123-------------------------------
2180 2124
@@ -2193,16 +2137,15 @@ Options:
2193 2137
2194Example: 2138Example:
2195 2139
2196$ echo -e a 2140 $ echo -e a
2197a 2141 a
2198b 2142 b
2199c 2143 c
2200c 2144 c
2201a | sort | uniq 2145 a | sort | uniq
2202a 2146 a
2203b 2147 b
2204c 2148 c
2205
2206 2149
2207------------------------------- 2150-------------------------------
2208 2151
@@ -2236,9 +2179,9 @@ Display the time since the last boot.
2236 2179
2237Example: 2180Example:
2238 2181
2239$ uptime 2182 $ uptime
2240 1:55pm up 2:30, load average: 0.09, 0.04, 0.00 2183 1:55pm up 2:30, load average: 0.09, 0.04, 0.00
2241 2184
2242 2185
2243------------------------------- 2186-------------------------------
2244 2187
@@ -2250,9 +2193,8 @@ Pause for N microseconds.
2250 2193
2251Example: 2194Example:
2252 2195
2253$ usleep 1000000 2196 $ usleep 1000000
2254[pauses for 1 second] 2197 [pauses for 1 second]
2255
2256 2198
2257------------------------------- 2199-------------------------------
2258 2200
@@ -2283,12 +2225,11 @@ Options:
2283 2225
2284Example: 2226Example:
2285 2227
2286$ uuencode busybox busybox 2228 $ uuencode busybox busybox
2287begin 755 busybox 2229 begin 755 busybox
2288M?T5,1@$!`0````````````(``P`!````L+@$..... 2230 <encoded file snipped>
2289$ uudecode busybox busybox > busybox.uu 2231 $ uudecode busybox busybox > busybox.uu
2290$ 2232 $
2291
2292 2233
2293------------------------------- 2234-------------------------------
2294 2235
@@ -2316,9 +2257,9 @@ Options:
2316 2257
2317Example: 2258Example:
2318 2259
2319$ wc /etc/passwd 2260 $ wc /etc/passwd
2320 31 46 1365 /etc/passwd 2261 31 46 1365 /etc/passwd
2321 2262
2322 2263
2323------------------------------- 2264-------------------------------
2324 2265
@@ -2343,9 +2284,8 @@ Locates a COMMAND.
2343 2284
2344Example: 2285Example:
2345 2286
2346$ which login 2287 $ which login
2347/bin/login 2288 /bin/login
2348
2349 2289
2350------------------------------- 2290-------------------------------
2351 2291
@@ -2365,9 +2305,9 @@ Executes COMMAND on every item given by standard input.
2365 2305
2366Example: 2306Example:
2367 2307
2368$ ls | xargs gzip 2308 $ ls | xargs gzip
2369$ find . -name '*.c' -print | xargs rm 2309 $ find . -name '*.c' -print | xargs rm
2370 2310
2371 2311
2372------------------------------- 2312-------------------------------
2373 2313
@@ -2375,7 +2315,7 @@ $ find . -name '*.c' -print | xargs rm
2375 2315
2376yes [OPTION]... [STRING]... 2316yes [OPTION]... [STRING]...
2377 2317
2378Repeatedly outputs a line with all specified STRING(s), or `y'. 2318Repeatedly outputs a line with all specified STRING(s), or 'y'.
2379 2319
2380------------------------------- 2320-------------------------------
2381 2321
@@ -2535,4 +2475,4 @@ Enrique Zanardi <ezanardi@ull.es>
2535 2475
2536=cut 2476=cut
2537 2477
2538# $Id: busybox.pod,v 1.90 2001/03/15 18:14:25 andersen Exp $ 2478# $Id: busybox.pod,v 1.91 2001/03/15 21:08:01 beppu Exp $