usage.h 186 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228
  1. /* vi: set sw=8 ts=8: */
  2. /*
  3. * This file suffers from chronically incorrect tabification
  4. * of messages. Before editing this file:
  5. * 1. Switch you editor to 8-space tab mode.
  6. * 2. Do not use \t in messages, use real tab character.
  7. * 3. Start each source line with message as follows:
  8. * |<7 spaces>"text with tabs"....
  9. * or
  10. * |<5 spaces>"\ntext with tabs"....
  11. */
  12. #ifndef BB_USAGE_H
  13. #define BB_USAGE_H 1
  14. #define NOUSAGE_STR "\b"
  15. #define acpid_trivial_usage \
  16. "[-d] [-c CONFDIR] [-l LOGFILE] [-e PROC_EVENT_FILE] [EVDEV_EVENT_FILE]..."
  17. #define acpid_full_usage "\n\n" \
  18. "Listen to ACPI events and spawn specific helpers on event arrival\n" \
  19. "\nOptions:" \
  20. "\n -d Don't daemonize, log to stderr" \
  21. "\n -c DIR Config directory [/etc/acpi]" \
  22. "\n -e FILE /proc event file [/proc/acpi/event]" \
  23. "\n -l FILE Log file [/var/log/acpid]" \
  24. IF_FEATURE_ACPID_COMPAT( \
  25. "\n\nAccept and ignore compatibility options -g -m -s -S -v" \
  26. )
  27. #define acpid_example_usage \
  28. "# acpid -l /var/log/my-acpi-log\n" \
  29. "# acpid -d /dev/input/event*\n"
  30. #define addgroup_trivial_usage \
  31. "[-g GID] " IF_FEATURE_ADDUSER_TO_GROUP("[USER] ") "GROUP"
  32. #define addgroup_full_usage "\n\n" \
  33. "Add a group " IF_FEATURE_ADDUSER_TO_GROUP("or add a user to a group") "\n" \
  34. "\nOptions:" \
  35. "\n -g GID Group id" \
  36. "\n -S Create a system group" \
  37. #define adduser_trivial_usage \
  38. "[OPTIONS] USER"
  39. #define adduser_full_usage "\n\n" \
  40. "Add a user\n" \
  41. "\nOptions:" \
  42. "\n -h DIR Home directory" \
  43. "\n -g GECOS GECOS field" \
  44. "\n -s SHELL Login shell" \
  45. "\n -G GRP Add user to existing group" \
  46. "\n -S Create a system user" \
  47. "\n -D Don't assign a password" \
  48. "\n -H Don't create home directory" \
  49. "\n -u UID User id" \
  50. #define adjtimex_trivial_usage \
  51. "[-q] [-o OFF] [-f FREQ] [-p TCONST] [-t TICK]"
  52. #define adjtimex_full_usage "\n\n" \
  53. "Read and optionally set system timebase parameters. See adjtimex(2)\n" \
  54. "\nOptions:" \
  55. "\n -q Quiet" \
  56. "\n -o OFF Time offset, microseconds" \
  57. "\n -f FREQ Frequency adjust, integer kernel units (65536 is 1ppm)" \
  58. "\n (positive values make clock run faster)" \
  59. "\n -t TICK Microseconds per tick, usually 10000" \
  60. "\n -p TCONST" \
  61. #define ar_trivial_usage \
  62. "[-o] [-v] [-p] [-t] [-x] ARCHIVE FILES"
  63. #define ar_full_usage "\n\n" \
  64. "Extract or list FILES from an ar archive\n" \
  65. "\nOptions:" \
  66. "\n -o Preserve original dates" \
  67. "\n -p Extract to stdout" \
  68. "\n -t List" \
  69. "\n -x Extract" \
  70. "\n -v Verbose" \
  71. #define arp_trivial_usage \
  72. "\n[-vn] [-H HWTYPE] [-i IF] -a [HOSTNAME]" \
  73. "\n[-v] [-i IF] -d HOSTNAME [pub]" \
  74. "\n[-v] [-H HWTYPE] [-i IF] -s HOSTNAME HWADDR [temp]" \
  75. "\n[-v] [-H HWTYPE] [-i IF] -s HOSTNAME HWADDR [netmask MASK] pub" \
  76. "\n[-v] [-H HWTYPE] [-i IF] -Ds HOSTNAME IFACE [netmask MASK] pub"
  77. #define arp_full_usage "\n\n" \
  78. "Manipulate ARP cache\n" \
  79. "\nOptions:" \
  80. "\n -a Display (all) hosts" \
  81. "\n -s Set new ARP entry" \
  82. "\n -d Delete a specified entry" \
  83. "\n -v Verbose" \
  84. "\n -n Don't resolve names" \
  85. "\n -i IF Network interface" \
  86. "\n -D Read <hwaddr> from given device" \
  87. "\n -A, -p AF Protocol family" \
  88. "\n -H HWTYPE Hardware address type" \
  89. #define arping_trivial_usage \
  90. "[-fqbDUA] [-c CNT] [-w TIMEOUT] [-I IFACE] [-s SRC_IP] DST_IP"
  91. #define arping_full_usage "\n\n" \
  92. "Send ARP requests/replies\n" \
  93. "\nOptions:" \
  94. "\n -f Quit on first ARP reply" \
  95. "\n -q Quiet" \
  96. "\n -b Keep broadcasting, don't go unicast" \
  97. "\n -D Duplicated address detection mode" \
  98. "\n -U Unsolicited ARP mode, update your neighbors" \
  99. "\n -A ARP answer mode, update your neighbors" \
  100. "\n -c N Stop after sending N ARP requests" \
  101. "\n -w TIMEOUT Time to wait for ARP reply, seconds" \
  102. "\n -I IFACE Interface to use (default eth0)" \
  103. "\n -s SRC_IP Sender IP address" \
  104. "\n DST_IP Target IP address" \
  105. #define sh_trivial_usage NOUSAGE_STR
  106. #define sh_full_usage ""
  107. #define ash_trivial_usage NOUSAGE_STR
  108. #define ash_full_usage ""
  109. #define hush_trivial_usage NOUSAGE_STR
  110. #define hush_full_usage ""
  111. #define lash_trivial_usage NOUSAGE_STR
  112. #define lash_full_usage ""
  113. #define msh_trivial_usage NOUSAGE_STR
  114. #define msh_full_usage ""
  115. #define awk_trivial_usage \
  116. "[OPTIONS] [AWK_PROGRAM] [FILE]..."
  117. #define awk_full_usage "\n\n" \
  118. "Options:" \
  119. "\n -v VAR=VAL Set variable" \
  120. "\n -F SEP Use SEP as field separator" \
  121. "\n -f FILE Read program from FILE" \
  122. #define basename_trivial_usage \
  123. "FILE [SUFFIX]"
  124. #define basename_full_usage "\n\n" \
  125. "Strip directory path and .SUFFIX from FILE\n"
  126. #define basename_example_usage \
  127. "$ basename /usr/local/bin/foo\n" \
  128. "foo\n" \
  129. "$ basename /usr/local/bin/\n" \
  130. "bin\n" \
  131. "$ basename /foo/bar.txt .txt\n" \
  132. "bar"
  133. #define beep_trivial_usage \
  134. "-f FREQ -l LEN -d DELAY -r COUNT -n"
  135. #define beep_full_usage "\n\n" \
  136. "Options:" \
  137. "\n -f Frequency in Hz" \
  138. "\n -l Length in ms" \
  139. "\n -d Delay in ms" \
  140. "\n -r Repetitions" \
  141. "\n -n Start new tone" \
  142. #define bootchartd_trivial_usage \
  143. "start [PROG ARGS]|stop|init"
  144. #define bootchartd_full_usage "\n\n" \
  145. "Create /var/log/bootchart.tgz with boot chart data\n" \
  146. "\nOptions:" \
  147. "\nstart: start background logging; with PROG, run PROG, then kill logging with USR1" \
  148. "\nstop: send USR1 to all bootchartd processes" \
  149. "\ninit: start background logging; stop when getty/xdm is seen (for init scripts)" \
  150. "\nUnder PID 1: as init, then exec $bootchart_init, /init, /sbin/init" \
  151. #define brctl_trivial_usage \
  152. "COMMAND [BRIDGE [INTERFACE]]"
  153. #define brctl_full_usage "\n\n" \
  154. "Manage ethernet bridges\n" \
  155. "\nCommands:" \
  156. IF_FEATURE_BRCTL_SHOW( \
  157. "\n show Show a list of bridges" \
  158. ) \
  159. "\n addbr BRIDGE Create BRIDGE" \
  160. "\n delbr BRIDGE Delete BRIDGE" \
  161. "\n addif BRIDGE IFACE Add IFACE to BRIDGE" \
  162. "\n delif BRIDGE IFACE Delete IFACE from BRIDGE" \
  163. IF_FEATURE_BRCTL_FANCY( \
  164. "\n setageing BRIDGE TIME Set ageing time" \
  165. "\n setfd BRIDGE TIME Set bridge forward delay" \
  166. "\n sethello BRIDGE TIME Set hello time" \
  167. "\n setmaxage BRIDGE TIME Set max message age" \
  168. "\n setpathcost BRIDGE COST Set path cost" \
  169. "\n setportprio BRIDGE PRIO Set port priority" \
  170. "\n setbridgeprio BRIDGE PRIO Set bridge priority" \
  171. "\n stp BRIDGE [1/yes/on|0/no/off] STP on/off" \
  172. ) \
  173. #define bunzip2_trivial_usage \
  174. "[OPTIONS] [FILE]..."
  175. #define bunzip2_full_usage "\n\n" \
  176. "Uncompress FILEs (or stdin)\n" \
  177. "\nOptions:" \
  178. "\n -c Write to stdout" \
  179. "\n -f Force" \
  180. #define bzip2_trivial_usage \
  181. "[OPTIONS] [FILE]..."
  182. #define bzip2_full_usage "\n\n" \
  183. "Compress FILEs (or stdin) with bzip2 algorithm\n" \
  184. "\nOptions:" \
  185. "\n -c Write to stdout" \
  186. "\n -d Decompress" \
  187. "\n -f Force" \
  188. "\n -1..-9 Compression level" \
  189. #define busybox_notes_usage \
  190. "Hello world!\n"
  191. #define lzop_trivial_usage \
  192. "[-cfvd123456789CF] [FILE]..."
  193. #define lzop_full_usage "\n\n" \
  194. " -c Write to stdout" \
  195. "\n -f Force" \
  196. "\n -v Verbose" \
  197. "\n -d Decompress" \
  198. "\n -F Don't store or verify checksum" \
  199. "\n -C Also write checksum of compressed block" \
  200. "\n -1..9 Compression level" \
  201. #define lzopcat_trivial_usage \
  202. "[-vCF] [FILE]..."
  203. #define lzopcat_full_usage "\n\n" \
  204. " -v Verbose" \
  205. "\n -F Don't store or verify checksum" \
  206. #define unlzop_trivial_usage \
  207. "[-cfvCF] [FILE]..."
  208. #define unlzop_full_usage "\n\n" \
  209. " -c Write to stdout" \
  210. "\n -f Force" \
  211. "\n -v Verbose" \
  212. "\n -F Don't store or verify checksum" \
  213. #define bzcat_trivial_usage \
  214. "FILE"
  215. #define bzcat_full_usage "\n\n" \
  216. "Uncompress to stdout"
  217. #define unlzma_trivial_usage \
  218. "[OPTIONS] [FILE]..."
  219. #define unlzma_full_usage "\n\n" \
  220. "Uncompress FILE (or stdin)\n" \
  221. "\nOptions:" \
  222. "\n -c Write to stdout" \
  223. "\n -f Force" \
  224. #define lzmacat_trivial_usage \
  225. "FILE"
  226. #define lzmacat_full_usage "\n\n" \
  227. "Uncompress to stdout"
  228. #define cal_trivial_usage \
  229. "[-jy] [[MONTH] YEAR]"
  230. #define cal_full_usage "\n\n" \
  231. "Display a calendar\n" \
  232. "\nOptions:" \
  233. "\n -j Use julian dates" \
  234. "\n -y Display the entire year" \
  235. #define cat_trivial_usage \
  236. "[-u] [FILE]..."
  237. #define cat_full_usage "\n\n" \
  238. "Concatenate FILEs and print them to stdout\n" \
  239. "\nOptions:" \
  240. "\n -u Use unbuffered i/o (ignored)" \
  241. #define cat_example_usage \
  242. "$ cat /proc/uptime\n" \
  243. "110716.72 17.67"
  244. #define catv_trivial_usage \
  245. "[-etv] [FILE]..."
  246. #define catv_full_usage "\n\n" \
  247. "Display nonprinting characters as ^x or M-x\n" \
  248. "\nOptions:" \
  249. "\n -e End each line with $" \
  250. "\n -t Show tabs as ^I" \
  251. "\n -v Don't use ^x or M-x escapes" \
  252. #define chat_trivial_usage \
  253. "EXPECT [SEND [EXPECT [SEND...]]]"
  254. #define chat_full_usage "\n\n" \
  255. "Useful for interacting with a modem connected to stdin/stdout.\n" \
  256. "A script consists of one or more \"expect-send\" pairs of strings,\n" \
  257. "each pair is a pair of arguments. Example:\n" \
  258. "chat '' ATZ OK ATD123456 CONNECT '' ogin: pppuser word: ppppass '~'" \
  259. #define chattr_trivial_usage \
  260. "[-R] [-+=AacDdijsStTu] [-v VERSION] [FILE]..."
  261. #define chattr_full_usage "\n\n" \
  262. "Change file attributes on an ext2 fs\n" \
  263. "\nModifiers:" \
  264. "\n - Remove attributes" \
  265. "\n + Add attributes" \
  266. "\n = Set attributes" \
  267. "\nAttributes:" \
  268. "\n A Don't track atime" \
  269. "\n a Append mode only" \
  270. "\n c Enable compress" \
  271. "\n D Write dir contents synchronously" \
  272. "\n d Don't backup with dump" \
  273. "\n i Cannot be modified (immutable)" \
  274. "\n j Write all data to journal first" \
  275. "\n s Zero disk storage when deleted" \
  276. "\n S Write file contents synchronously" \
  277. "\n t Disable tail-merging of partial blocks with other files" \
  278. "\n u Allow file to be undeleted" \
  279. "\nOptions:" \
  280. "\n -R Recurse" \
  281. "\n -v Set the file's version/generation number" \
  282. #define chcon_trivial_usage \
  283. "[OPTIONS] CONTEXT FILE..." \
  284. "\n chcon [OPTIONS] [-u USER] [-r ROLE] [-l RANGE] [-t TYPE] FILE..." \
  285. IF_FEATURE_CHCON_LONG_OPTIONS( \
  286. "\n chcon [OPTIONS] --reference=RFILE FILE..." \
  287. )
  288. #define chcon_full_usage "\n\n" \
  289. "Change the security context of each FILE to CONTEXT\n" \
  290. IF_FEATURE_CHCON_LONG_OPTIONS( \
  291. "\n -v,--verbose Verbose" \
  292. "\n -c,--changes Report changes made" \
  293. "\n -h,--no-dereference Affect symlinks instead of their targets" \
  294. "\n -f,--silent,--quiet Suppress most error messages" \
  295. "\n --reference=RFILE Use RFILE's group instead of using a CONTEXT value" \
  296. "\n -u,--user=USER Set user/role/type/range in the target" \
  297. "\n -r,--role=ROLE security context" \
  298. "\n -t,--type=TYPE" \
  299. "\n -l,--range=RANGE" \
  300. "\n -R,--recursive Recurse" \
  301. ) \
  302. IF_NOT_FEATURE_CHCON_LONG_OPTIONS( \
  303. "\n -v Verbose" \
  304. "\n -c Report changes made" \
  305. "\n -h Affect symlinks instead of their targets" \
  306. "\n -f Suppress most error messages" \
  307. "\n -u USER Set user/role/type/range in the target security context" \
  308. "\n -r ROLE" \
  309. "\n -t TYPE" \
  310. "\n -l RNG" \
  311. "\n -R Recurse" \
  312. )
  313. #define chmod_trivial_usage \
  314. "[-R"IF_DESKTOP("cvf")"] MODE[,MODE]... FILE..."
  315. #define chmod_full_usage "\n\n" \
  316. "Each MODE is one or more of the letters ugoa, one of the\n" \
  317. "symbols +-= and one or more of the letters rwxst\n" \
  318. "\nOptions:" \
  319. "\n -R Recurse" \
  320. IF_DESKTOP( \
  321. "\n -c List changed files" \
  322. "\n -v List all files" \
  323. "\n -f Hide errors" \
  324. )
  325. #define chmod_example_usage \
  326. "$ ls -l /tmp/foo\n" \
  327. "-rw-rw-r-- 1 root root 0 Apr 12 18:25 /tmp/foo\n" \
  328. "$ chmod u+x /tmp/foo\n" \
  329. "$ ls -l /tmp/foo\n" \
  330. "-rwxrw-r-- 1 root root 0 Apr 12 18:25 /tmp/foo*\n" \
  331. "$ chmod 444 /tmp/foo\n" \
  332. "$ ls -l /tmp/foo\n" \
  333. "-r--r--r-- 1 root root 0 Apr 12 18:25 /tmp/foo\n"
  334. #define chgrp_trivial_usage \
  335. "[-RhLHP"IF_DESKTOP("cvf")"]... GROUP FILE..."
  336. #define chgrp_full_usage "\n\n" \
  337. "Change the group membership of each FILE to GROUP\n" \
  338. "\nOptions:" \
  339. "\n -R Recurse" \
  340. "\n -h Affect symlinks instead of symlink targets" \
  341. "\n -L Traverse all symlinks to directories" \
  342. "\n -H Traverse symlinks on command line only" \
  343. "\n -P Don't traverse symlinks (default)" \
  344. IF_DESKTOP( \
  345. "\n -c List changed files" \
  346. "\n -v Verbose" \
  347. "\n -f Hide errors" \
  348. )
  349. #define chgrp_example_usage \
  350. "$ ls -l /tmp/foo\n" \
  351. "-r--r--r-- 1 andersen andersen 0 Apr 12 18:25 /tmp/foo\n" \
  352. "$ chgrp root /tmp/foo\n" \
  353. "$ ls -l /tmp/foo\n" \
  354. "-r--r--r-- 1 andersen root 0 Apr 12 18:25 /tmp/foo\n"
  355. #define chown_trivial_usage \
  356. "[-RhLHP"IF_DESKTOP("cvf")"]... OWNER[<.|:>[GROUP]] FILE..."
  357. #define chown_full_usage "\n\n" \
  358. "Change the owner and/or group of each FILE to OWNER and/or GROUP\n" \
  359. "\nOptions:" \
  360. "\n -R Recurse" \
  361. "\n -h Affect symlinks instead of symlink targets" \
  362. "\n -L Traverse all symlinks to directories" \
  363. "\n -H Traverse symlinks on command line only" \
  364. "\n -P Don't traverse symlinks (default)" \
  365. IF_DESKTOP( \
  366. "\n -c List changed files" \
  367. "\n -v List all files" \
  368. "\n -f Hide errors" \
  369. )
  370. #define chown_example_usage \
  371. "$ ls -l /tmp/foo\n" \
  372. "-r--r--r-- 1 andersen andersen 0 Apr 12 18:25 /tmp/foo\n" \
  373. "$ chown root /tmp/foo\n" \
  374. "$ ls -l /tmp/foo\n" \
  375. "-r--r--r-- 1 root andersen 0 Apr 12 18:25 /tmp/foo\n" \
  376. "$ chown root.root /tmp/foo\n" \
  377. "ls -l /tmp/foo\n" \
  378. "-r--r--r-- 1 root root 0 Apr 12 18:25 /tmp/foo\n"
  379. #define chpst_trivial_usage \
  380. "[-vP012] [-u USER[:GRP]] [-U USER[:GRP]] [-e DIR]\n" \
  381. " [-/ DIR] [-n NICE] [-m BYTES] [-d BYTES] [-o N]\n" \
  382. " [-p N] [-f BYTES] [-c BYTES] PROG ARGS"
  383. #define chpst_full_usage "\n\n" \
  384. "Change the process state and run PROG\n" \
  385. "\nOptions:" \
  386. "\n -u USER[:GRP] Set uid and gid" \
  387. "\n -U USER[:GRP] Set $UID and $GID in environment" \
  388. "\n -e DIR Set environment variables as specified by files" \
  389. "\n in DIR: file=1st_line_of_file" \
  390. "\n -/ DIR Chroot to DIR" \
  391. "\n -n NICE Add NICE to nice value" \
  392. "\n -m BYTES Same as -d BYTES -s BYTES -l BYTES" \
  393. "\n -d BYTES Limit data segment" \
  394. "\n -o N Limit number of open files per process" \
  395. "\n -p N Limit number of processes per uid" \
  396. "\n -f BYTES Limit output file sizes" \
  397. "\n -c BYTES Limit core file size" \
  398. "\n -v Verbose" \
  399. "\n -P Create new process group" \
  400. "\n -0 Close stdin" \
  401. "\n -1 Close stdout" \
  402. "\n -2 Close stderr" \
  403. #define setuidgid_trivial_usage \
  404. "USER PROG ARGS"
  405. #define setuidgid_full_usage "\n\n" \
  406. "Set uid and gid to USER's uid and gid, removing all supplementary\n" \
  407. "groups and run PROG"
  408. #define envuidgid_trivial_usage \
  409. "USER PROG ARGS"
  410. #define envuidgid_full_usage "\n\n" \
  411. "Set $UID to USER's uid and $GID to USER's gid and run PROG"
  412. #define envdir_trivial_usage \
  413. "DIR PROG ARGS"
  414. #define envdir_full_usage "\n\n" \
  415. "Set various environment variables as specified by files\n" \
  416. "in the directory dir and run PROG"
  417. #define softlimit_trivial_usage \
  418. "[-a BYTES] [-m BYTES] [-d BYTES] [-s BYTES] [-l BYTES]\n" \
  419. " [-f BYTES] [-c BYTES] [-r BYTES] [-o N] [-p N] [-t N]\n" \
  420. " PROG ARGS"
  421. #define softlimit_full_usage "\n\n" \
  422. "Set soft resource limits, then run PROG\n" \
  423. "\nOptions:" \
  424. "\n -a BYTES Limit total size of all segments" \
  425. "\n -m BYTES Same as -d BYTES -s BYTES -l BYTES -a BYTES" \
  426. "\n -d BYTES Limit data segment" \
  427. "\n -s BYTES Limit stack segment" \
  428. "\n -l BYTES Limit locked memory size" \
  429. "\n -o N Limit number of open files per process" \
  430. "\n -p N Limit number of processes per uid" \
  431. "\nOptions controlling file sizes:" \
  432. "\n -f BYTES Limit output file sizes" \
  433. "\n -c BYTES Limit core file size" \
  434. "\nEfficiency opts:" \
  435. "\n -r BYTES Limit resident set size" \
  436. "\n -t N Limit CPU time, process receives" \
  437. "\n a SIGXCPU after N seconds" \
  438. #define chroot_trivial_usage \
  439. "NEWROOT [PROG ARGS]"
  440. #define chroot_full_usage "\n\n" \
  441. "Run PROG with root directory set to NEWROOT"
  442. #define chroot_example_usage \
  443. "$ ls -l /bin/ls\n" \
  444. "lrwxrwxrwx 1 root root 12 Apr 13 00:46 /bin/ls -> /BusyBox\n" \
  445. "# mount /dev/hdc1 /mnt -t minix\n" \
  446. "# chroot /mnt\n" \
  447. "# ls -l /bin/ls\n" \
  448. "-rwxr-xr-x 1 root root 40816 Feb 5 07:45 /bin/ls*\n"
  449. #define chvt_trivial_usage \
  450. "N"
  451. #define chvt_full_usage "\n\n" \
  452. "Change the foreground virtual terminal to /dev/ttyN"
  453. #define cksum_trivial_usage \
  454. "FILES..."
  455. #define cksum_full_usage "\n\n" \
  456. "Calculate the CRC32 checksums of FILES"
  457. #define clear_trivial_usage \
  458. ""
  459. #define clear_full_usage "\n\n" \
  460. "Clear screen"
  461. #define cmp_trivial_usage \
  462. "[-l] [-s] FILE1 [FILE2" IF_DESKTOP(" [SKIP1 [SKIP2]]") "]"
  463. #define cmp_full_usage "\n\n" \
  464. "Compare FILE1 with FILE2 (or stdin)\n" \
  465. "\nOptions:" \
  466. "\n -l Write the byte numbers (decimal) and values (octal)" \
  467. "\n for all differing bytes" \
  468. "\n -s Quiet" \
  469. #define comm_trivial_usage \
  470. "[-123] FILE1 FILE2"
  471. #define comm_full_usage "\n\n" \
  472. "Compare FILE1 with FILE2\n" \
  473. "\nOptions:" \
  474. "\n -1 Suppress lines unique to FILE1" \
  475. "\n -2 Suppress lines unique to FILE2" \
  476. "\n -3 Suppress lines common to both files" \
  477. #define bbconfig_trivial_usage \
  478. ""
  479. #define bbconfig_full_usage "\n\n" \
  480. "Print the config file which built busybox"
  481. #define chrt_trivial_usage \
  482. "[OPTIONS] [PRIO] [PID | PROG ARGS]"
  483. #define chrt_full_usage "\n\n" \
  484. "Manipulate real-time attributes of a process\n" \
  485. "\nOptions:" \
  486. "\n -p Operate on PID" \
  487. "\n -r Set SCHED_RR scheduling" \
  488. "\n -f Set SCHED_FIFO scheduling" \
  489. "\n -o Set SCHED_OTHER scheduling" \
  490. "\n -m Show min and max priorities" \
  491. #define chrt_example_usage \
  492. "$ chrt -r 4 sleep 900; x=$!\n" \
  493. "$ chrt -f -p 3 $x\n" \
  494. "You need CAP_SYS_NICE privileges to set scheduling attributes of a process"
  495. #define cp_trivial_usage \
  496. "[OPTIONS] SOURCE DEST"
  497. #define cp_full_usage "\n\n" \
  498. "Copy SOURCE to DEST, or multiple SOURCE(s) to DIRECTORY\n" \
  499. "\nOptions:" \
  500. "\n -a Same as -dpR" \
  501. IF_SELINUX( \
  502. "\n -c Preserve security context" \
  503. ) \
  504. "\n -R,-r Recurse" \
  505. "\n -d,-P Preserve symlinks (default if -R)" \
  506. "\n -L Follow all symlinks" \
  507. "\n -H Follow symlinks on command line" \
  508. "\n -p Preserve file attributes if possible" \
  509. "\n -f Force overwrite" \
  510. "\n -i Prompt before overwrite" \
  511. "\n -l,-s Create (sym)links" \
  512. #define cpio_trivial_usage \
  513. "[-dmvu] [-F FILE]" IF_FEATURE_CPIO_O(" [-H newc]") \
  514. " [-ti"IF_FEATURE_CPIO_O("o")"]" IF_FEATURE_CPIO_P(" [-p DIR]")
  515. #define cpio_full_usage "\n\n" \
  516. "Extract or list files from a cpio archive" \
  517. IF_FEATURE_CPIO_O(", or" \
  518. "\ncreate an archive" IF_FEATURE_CPIO_P(" (-o) or copy files (-p)") \
  519. " using file list on stdin" \
  520. ) \
  521. "\n" \
  522. "\nMain operation mode:" \
  523. "\n -t List" \
  524. "\n -i Extract" \
  525. IF_FEATURE_CPIO_O( \
  526. "\n -o Create (requires -H newc)" \
  527. ) \
  528. IF_FEATURE_CPIO_P( \
  529. "\n -p DIR Copy files to DIR" \
  530. ) \
  531. "\nOptions:" \
  532. "\n -d Make leading directories" \
  533. "\n -m Preserve mtime" \
  534. "\n -v Verbose" \
  535. "\n -u Overwrite" \
  536. "\n -F FILE Input (-t,-i,-p) or output (-o) file" \
  537. IF_FEATURE_CPIO_O( \
  538. "\n -H newc Archive format" \
  539. ) \
  540. #define crond_trivial_usage \
  541. "-fbS -l N " IF_FEATURE_CROND_D("-d N ") "-L LOGFILE -c DIR"
  542. #define crond_full_usage "\n\n" \
  543. " -f Foreground" \
  544. "\n -b Background (default)" \
  545. "\n -S Log to syslog (default)" \
  546. "\n -l Set log level. 0 is the most verbose, default 8" \
  547. IF_FEATURE_CROND_D( \
  548. "\n -d Set log level, log to stderr" \
  549. ) \
  550. "\n -L Log to file" \
  551. "\n -c Working dir" \
  552. #define crontab_trivial_usage \
  553. "[-c DIR] [-u USER] [-ler]|[FILE]"
  554. #define crontab_full_usage "\n\n" \
  555. " -c Crontab directory" \
  556. "\n -u User" \
  557. "\n -l List crontab" \
  558. "\n -e Edit crontab" \
  559. "\n -r Delete crontab" \
  560. "\n FILE Replace crontab by FILE ('-': stdin)" \
  561. #define cryptpw_trivial_usage \
  562. "[OPTIONS] [PASSWORD] [SALT]"
  563. /* We do support -s, we just don't mention it */
  564. #define cryptpw_full_usage "\n\n" \
  565. "Crypt the PASSWORD using crypt(3)\n" \
  566. "\nOptions:" \
  567. IF_LONG_OPTS( \
  568. "\n -P,--password-fd=N Read password from fd N" \
  569. /* "\n -s,--stdin Use stdin; like -P0" */ \
  570. "\n -m,--method=TYPE Encryption method TYPE" \
  571. "\n -S,--salt=SALT" \
  572. ) \
  573. IF_NOT_LONG_OPTS( \
  574. "\n -P N Read password from fd N" \
  575. /* "\n -s Use stdin; like -P0" */ \
  576. "\n -m TYPE Encryption method TYPE" \
  577. "\n -S SALT" \
  578. ) \
  579. /* mkpasswd is an alias to cryptpw */
  580. #define mkpasswd_trivial_usage \
  581. "[OPTIONS] [PASSWORD] [SALT]"
  582. /* We do support -s, we just don't mention it */
  583. #define mkpasswd_full_usage "\n\n" \
  584. "Crypt the PASSWORD using crypt(3)\n" \
  585. "\nOptions:" \
  586. IF_LONG_OPTS( \
  587. "\n -P,--password-fd=N Read password from fd N" \
  588. /* "\n -s,--stdin Use stdin; like -P0" */ \
  589. "\n -m,--method=TYPE Encryption method TYPE" \
  590. "\n -S,--salt=SALT" \
  591. ) \
  592. IF_NOT_LONG_OPTS( \
  593. "\n -P N Read password from fd N" \
  594. /* "\n -s Use stdin; like -P0" */ \
  595. "\n -m TYPE Encryption method TYPE" \
  596. "\n -S SALT" \
  597. ) \
  598. #define cttyhack_trivial_usage NOUSAGE_STR
  599. #define cttyhack_full_usage ""
  600. #define cut_trivial_usage \
  601. "[OPTIONS] [FILE]..."
  602. #define cut_full_usage "\n\n" \
  603. "Print selected fields from each input FILE to stdout\n" \
  604. "\nOptions:" \
  605. "\n -b LIST Output only bytes from LIST" \
  606. "\n -c LIST Output only characters from LIST" \
  607. "\n -d CHAR Use CHAR instead of tab as the field delimiter" \
  608. "\n -s Output only the lines containing delimiter" \
  609. "\n -f N Print only these fields" \
  610. "\n -n Ignored" \
  611. #define cut_example_usage \
  612. "$ echo \"Hello world\" | cut -f 1 -d ' '\n" \
  613. "Hello\n" \
  614. "$ echo \"Hello world\" | cut -f 2 -d ' '\n" \
  615. "world\n"
  616. #define date_trivial_usage \
  617. "[OPTIONS] [+FMT] [TIME]"
  618. #define date_full_usage "\n\n" \
  619. "Display time (using +FMT), or set time\n" \
  620. "\nOptions:" \
  621. IF_NOT_LONG_OPTS( \
  622. "\n [-s] TIME Set time to TIME" \
  623. "\n -u Work in UTC (don't convert to local time)" \
  624. "\n -R Output RFC-2822 compliant date string" \
  625. ) IF_LONG_OPTS( \
  626. "\n [-s,--set] TIME Set time to TIME" \
  627. "\n -u,--utc Work in UTC (don't convert to local time)" \
  628. "\n -R,--rfc-2822 Output RFC-2822 compliant date string" \
  629. ) \
  630. IF_FEATURE_DATE_ISOFMT( \
  631. "\n -I[SPEC] Output ISO-8601 compliant date string" \
  632. "\n SPEC='date' (default) for date only," \
  633. "\n 'hours', 'minutes', or 'seconds' for date and" \
  634. "\n time to the indicated precision" \
  635. ) IF_NOT_LONG_OPTS( \
  636. "\n -r FILE Display last modification time of FILE" \
  637. "\n -d TIME Display TIME, not 'now'" \
  638. ) IF_LONG_OPTS( \
  639. "\n -r,--reference FILE Display last modification time of FILE" \
  640. "\n -d,--date TIME Display TIME, not 'now'" \
  641. ) \
  642. IF_FEATURE_DATE_ISOFMT( \
  643. "\n -D FMT Use FMT for -d TIME conversion" \
  644. ) \
  645. "\n" \
  646. "\nRecognized TIME formats:" \
  647. "\n hh:mm[:ss]" \
  648. "\n [YYYY.]MM.DD-hh:mm[:ss]" \
  649. "\n YYYY-MM-DD hh:mm[:ss]" \
  650. "\n [[[[[YY]YY]MM]DD]hh]mm[.ss]" \
  651. #define date_example_usage \
  652. "$ date\n" \
  653. "Wed Apr 12 18:52:41 MDT 2000\n"
  654. #define dc_trivial_usage \
  655. "expression..."
  656. #define dc_full_usage "\n\n" \
  657. "Tiny RPN calculator. Operations:\n" \
  658. "+, add, -, sub, *, mul, /, div, %, mod, **, exp, and, or, not, eor,\n" \
  659. "p - print top of the stack (without altering the stack),\n" \
  660. "f - print entire stack, o - pop the value and set output radix\n" \
  661. "(value must be 10 or 16).\n" \
  662. "Examples: 'dc 2 2 add' -> 4, 'dc 8 8 * 2 2 + /' -> 16\n" \
  663. #define dc_example_usage \
  664. "$ dc 2 2 + p\n" \
  665. "4\n" \
  666. "$ dc 8 8 \\* 2 2 + / p\n" \
  667. "16\n" \
  668. "$ dc 0 1 and p\n" \
  669. "0\n" \
  670. "$ dc 0 1 or p\n" \
  671. "1\n" \
  672. "$ echo 72 9 div 8 mul p | dc\n" \
  673. "64\n"
  674. #define dd_trivial_usage \
  675. "[if=FILE] [of=FILE] " IF_FEATURE_DD_IBS_OBS("[ibs=N] [obs=N] ") "[bs=N] [count=N] [skip=N]\n" \
  676. " [seek=N]" IF_FEATURE_DD_IBS_OBS(" [conv=notrunc|noerror|sync|fsync]")
  677. #define dd_full_usage "\n\n" \
  678. "Copy a file with converting and formatting\n" \
  679. "\nOptions:" \
  680. "\n if=FILE Read from FILE instead of stdin" \
  681. "\n of=FILE Write to FILE instead of stdout" \
  682. "\n bs=N Read and write N bytes at a time" \
  683. IF_FEATURE_DD_IBS_OBS( \
  684. "\n ibs=N Read N bytes at a time" \
  685. ) \
  686. IF_FEATURE_DD_IBS_OBS( \
  687. "\n obs=N Write N bytes at a time" \
  688. ) \
  689. "\n count=N Copy only N input blocks" \
  690. "\n skip=N Skip N input blocks" \
  691. "\n seek=N Skip N output blocks" \
  692. IF_FEATURE_DD_IBS_OBS( \
  693. "\n conv=notrunc Don't truncate output file" \
  694. "\n conv=noerror Continue after read errors" \
  695. "\n conv=sync Pad blocks with zeros" \
  696. "\n conv=fsync Physically write data out before finishing" \
  697. ) \
  698. "\n" \
  699. "\nNumbers may be suffixed by c (x1), w (x2), b (x512), kD (x1000), k (x1024)," \
  700. "\nMD (x1000000), M (x1048576), GD (x1000000000) or G (x1073741824)" \
  701. #define dd_example_usage \
  702. "$ dd if=/dev/zero of=/dev/ram1 bs=1M count=4\n" \
  703. "4+0 records in\n" \
  704. "4+0 records out\n"
  705. #define deallocvt_trivial_usage \
  706. "[N]"
  707. #define deallocvt_full_usage "\n\n" \
  708. "Deallocate unused virtual terminal /dev/ttyN"
  709. #define delgroup_trivial_usage \
  710. IF_FEATURE_DEL_USER_FROM_GROUP("[USER] ")"GROUP"
  711. #define delgroup_full_usage "\n\n" \
  712. "Delete group GROUP from the system" \
  713. IF_FEATURE_DEL_USER_FROM_GROUP(" or user USER from group GROUP")
  714. #define deluser_trivial_usage \
  715. "USER"
  716. #define deluser_full_usage "\n\n" \
  717. "Delete USER from the system"
  718. #define depmod_trivial_usage NOUSAGE_STR
  719. #define depmod_full_usage ""
  720. #define devmem_trivial_usage \
  721. "ADDRESS [WIDTH [VALUE]]"
  722. #define devmem_full_usage "\n\n" \
  723. "Read/write from physical address\n" \
  724. "\n ADDRESS Address to act upon" \
  725. "\n WIDTH Width (8/16/...)" \
  726. "\n VALUE Data to be written" \
  727. #define devfsd_trivial_usage \
  728. "mntpnt [-v]" IF_DEVFSD_FG_NP("[-fg][-np]")
  729. #define devfsd_full_usage "\n\n" \
  730. "Manage devfs permissions and old device name symlinks\n" \
  731. "\nOptions:" \
  732. "\n mntpnt The mount point where devfs is mounted" \
  733. "\n -v Print the protocol version numbers for devfsd" \
  734. "\n and the kernel-side protocol version and exit" \
  735. IF_DEVFSD_FG_NP( \
  736. "\n -fg Run in foreground" \
  737. "\n -np Exit after parsing the configuration file" \
  738. "\n and processing synthetic REGISTER events," \
  739. "\n don't poll for events" \
  740. )
  741. #define df_trivial_usage \
  742. "[-Pk" \
  743. IF_FEATURE_HUMAN_READABLE("mh") \
  744. IF_FEATURE_DF_FANCY("ai] [-B SIZE") \
  745. "] [FILESYSTEM]..."
  746. #define df_full_usage "\n\n" \
  747. "Print filesystem usage statistics\n" \
  748. "\nOptions:" \
  749. "\n -P POSIX output format" \
  750. "\n -k 1024-byte blocks (default)" \
  751. IF_FEATURE_HUMAN_READABLE( \
  752. "\n -m 1M-byte blocks" \
  753. "\n -h Human readable (e.g. 1K 243M 2G)" \
  754. ) \
  755. IF_FEATURE_DF_FANCY( \
  756. "\n -a Show all filesystems" \
  757. "\n -i Inodes" \
  758. "\n -B SIZE Blocksize" \
  759. ) \
  760. #define df_example_usage \
  761. "$ df\n" \
  762. "Filesystem 1K-blocks Used Available Use% Mounted on\n" \
  763. "/dev/sda3 8690864 8553540 137324 98% /\n" \
  764. "/dev/sda1 64216 36364 27852 57% /boot\n" \
  765. "$ df /dev/sda3\n" \
  766. "Filesystem 1K-blocks Used Available Use% Mounted on\n" \
  767. "/dev/sda3 8690864 8553540 137324 98% /\n" \
  768. "$ POSIXLY_CORRECT=sure df /dev/sda3\n" \
  769. "Filesystem 512B-blocks Used Available Use% Mounted on\n" \
  770. "/dev/sda3 17381728 17107080 274648 98% /\n" \
  771. "$ POSIXLY_CORRECT=yep df -P /dev/sda3\n" \
  772. "Filesystem 512-blocks Used Available Capacity Mounted on\n" \
  773. "/dev/sda3 17381728 17107080 274648 98% /\n"
  774. #define dhcprelay_trivial_usage \
  775. "CLIENT_IFACE[,CLIENT_IFACE2]... SERVER_IFACE [SERVER_IP]"
  776. #define dhcprelay_full_usage "\n\n" \
  777. "Relay DHCP requests between clients and server" \
  778. #define diff_trivial_usage \
  779. "[-abBdiNqrTstw] [-L LABEL] [-S FILE] [-U LINES] FILE1 FILE2"
  780. #define diff_full_usage "\n\n" \
  781. "Compare files line by line and output the differences between them.\n" \
  782. "This implementation supports unified diffs only.\n" \
  783. "\nOptions:" \
  784. "\n -a Treat all files as text" \
  785. "\n -b Ignore changes in the amount of whitespace" \
  786. "\n -B Ignore changes whose lines are all blank" \
  787. "\n -d Try hard to find a smaller set of changes" \
  788. "\n -i Ignore case differences" \
  789. "\n -L Use LABEL instead of the filename in the unified header" \
  790. "\n -N Treat absent files as empty" \
  791. "\n -q Output only whether files differ" \
  792. "\n -r Recurse" \
  793. "\n -S Start with FILE when comparing directories" \
  794. "\n -T Make tabs line up by prefixing a tab when necessary" \
  795. "\n -s Report when two files are the same" \
  796. "\n -t Expand tabs to spaces in output" \
  797. "\n -U Output LINES lines of context" \
  798. "\n -w Ignore all whitespace" \
  799. #define dirname_trivial_usage \
  800. "FILENAME"
  801. #define dirname_full_usage "\n\n" \
  802. "Strip non-directory suffix from FILENAME"
  803. #define dirname_example_usage \
  804. "$ dirname /tmp/foo\n" \
  805. "/tmp\n" \
  806. "$ dirname /tmp/foo/\n" \
  807. "/tmp\n"
  808. #define dmesg_trivial_usage \
  809. "[-c] [-n LEVEL] [-s SIZE]"
  810. #define dmesg_full_usage "\n\n" \
  811. "Print or control the kernel ring buffer\n" \
  812. "\nOptions:" \
  813. "\n -c Clear ring buffer after printing" \
  814. "\n -n LEVEL Set console logging level" \
  815. "\n -s SIZE Buffer size" \
  816. #define dnsd_trivial_usage \
  817. "[-dvs] [-c CONFFILE] [-t TTL_SEC] [-p PORT] [-i ADDR]"
  818. #define dnsd_full_usage "\n\n" \
  819. "Small static DNS server daemon\n" \
  820. "\nOptions:" \
  821. "\n -c FILE Config file" \
  822. "\n -t SEC TTL" \
  823. "\n -p PORT Listen on PORT" \
  824. "\n -i ADDR Listen on ADDR" \
  825. "\n -d Daemonize" \
  826. "\n -v Verbose" \
  827. "\n -s Send successful replies only. Use this if you want" \
  828. "\n to use /etc/resolv.conf with two nameserver lines:" \
  829. "\n nameserver DNSD_SERVER" \
  830. "\n nameserver NORNAL_DNS_SERVER" \
  831. #define dos2unix_trivial_usage \
  832. "[OPTIONS] [FILE]"
  833. #define dos2unix_full_usage "\n\n" \
  834. "Convert FILE in-place from DOS to Unix format.\n" \
  835. "When no file is given, use stdin/stdout.\n" \
  836. "\nOptions:" \
  837. "\n -u dos2unix" \
  838. "\n -d unix2dos" \
  839. #define unix2dos_trivial_usage \
  840. "[OPTIONS] [FILE]"
  841. #define unix2dos_full_usage "\n\n" \
  842. "Convert FILE in-place from Unix to DOS format.\n" \
  843. "When no file is given, use stdin/stdout.\n" \
  844. "\nOptions:" \
  845. "\n -u dos2unix" \
  846. "\n -d unix2dos" \
  847. #define dpkg_trivial_usage \
  848. "[-ilCPru] [-F OPT] PACKAGE"
  849. #define dpkg_full_usage "\n\n" \
  850. "Install, remove and manage Debian packages\n" \
  851. "\nOptions:" \
  852. IF_LONG_OPTS( \
  853. "\n -i,--install Install the package" \
  854. "\n -l,--list List of installed packages" \
  855. "\n --configure Configure an unpackaged package" \
  856. "\n -P,--purge Purge all files of a package" \
  857. "\n -r,--remove Remove all but the configuration files for a package" \
  858. "\n --unpack Unpack a package, but don't configure it" \
  859. "\n --force-depends Ignore dependency problems" \
  860. "\n --force-confnew Overwrite existing config files when installing" \
  861. "\n --force-confold Keep old config files when installing" \
  862. ) \
  863. IF_NOT_LONG_OPTS( \
  864. "\n -i Install the package" \
  865. "\n -l List of installed packages" \
  866. "\n -C Configure an unpackaged package" \
  867. "\n -P Purge all files of a package" \
  868. "\n -r Remove all but the configuration files for a package" \
  869. "\n -u Unpack a package, but don't configure it" \
  870. "\n -F depends Ignore dependency problems" \
  871. "\n -F confnew Overwrite existing config files when installing" \
  872. "\n -F confold Keep old config files when installing" \
  873. )
  874. #define dpkg_deb_trivial_usage \
  875. "[-cefxX] FILE [argument]"
  876. #define dpkg_deb_full_usage "\n\n" \
  877. "Perform actions on Debian packages (.debs)\n" \
  878. "\nOptions:" \
  879. "\n -c List contents of filesystem tree" \
  880. "\n -e Extract control files to [argument] directory" \
  881. "\n -f Display control field name starting with [argument]" \
  882. "\n -x Extract packages filesystem tree to directory" \
  883. "\n -X Verbose extract" \
  884. #define dpkg_deb_example_usage \
  885. "$ dpkg-deb -X ./busybox_0.48-1_i386.deb /tmp\n"
  886. #define du_trivial_usage \
  887. "[-aHLdclsx" IF_FEATURE_HUMAN_READABLE("hm") "k] [FILE]..."
  888. #define du_full_usage "\n\n" \
  889. "Summarize disk space used for each FILE and/or directory.\n" \
  890. "Disk space is printed in units of " \
  891. IF_FEATURE_DU_DEFAULT_BLOCKSIZE_1K("1024") \
  892. IF_NOT_FEATURE_DU_DEFAULT_BLOCKSIZE_1K("512") \
  893. " bytes.\n" \
  894. "\nOptions:" \
  895. "\n -a Show file sizes too" \
  896. "\n -L Follow all symlinks" \
  897. "\n -H Follow symlinks on command line" \
  898. "\n -d N Limit output to directories (and files with -a) of depth < N" \
  899. "\n -c Show grand total" \
  900. "\n -l Count sizes many times if hard linked" \
  901. "\n -s Display only a total for each argument" \
  902. "\n -x Skip directories on different filesystems" \
  903. IF_FEATURE_HUMAN_READABLE( \
  904. "\n -h Sizes in human readable format (e.g., 1K 243M 2G )" \
  905. "\n -m Sizes in megabytes" \
  906. ) \
  907. "\n -k Sizes in kilobytes" \
  908. IF_FEATURE_DU_DEFAULT_BLOCKSIZE_1K(" (default)") \
  909. #define du_example_usage \
  910. "$ du\n" \
  911. "16 ./CVS\n" \
  912. "12 ./kernel-patches/CVS\n" \
  913. "80 ./kernel-patches\n" \
  914. "12 ./tests/CVS\n" \
  915. "36 ./tests\n" \
  916. "12 ./scripts/CVS\n" \
  917. "16 ./scripts\n" \
  918. "12 ./docs/CVS\n" \
  919. "104 ./docs\n" \
  920. "2417 .\n"
  921. #define dumpkmap_trivial_usage \
  922. "> keymap"
  923. #define dumpkmap_full_usage "\n\n" \
  924. "Print a binary keyboard translation table to stdout"
  925. #define dumpkmap_example_usage \
  926. "$ dumpkmap > keymap\n"
  927. #define dumpleases_trivial_usage \
  928. "[-r|-a] [-f LEASEFILE]"
  929. #define dumpleases_full_usage "\n\n" \
  930. "Display DHCP leases granted by udhcpd\n" \
  931. "\nOptions:" \
  932. IF_LONG_OPTS( \
  933. "\n -f,--file=FILE Lease file" \
  934. "\n -r,--remaining Show remaining time" \
  935. "\n -a,--absolute Show expiration time" \
  936. ) \
  937. IF_NOT_LONG_OPTS( \
  938. "\n -f FILE Lease file" \
  939. "\n -r Show remaining time" \
  940. "\n -a Show expiration time" \
  941. )
  942. /*
  943. #define e2fsck_trivial_usage \
  944. "[-panyrcdfvstDFSV] [-b superblock] [-B blocksize] " \
  945. "[-I inode_buffer_blocks] [-P process_inode_size] " \
  946. "[-l|-L bad_blocks_file] [-C fd] [-j external_journal] " \
  947. "[-E extended-options] device"
  948. #define e2fsck_full_usage "\n\n" \
  949. "Check ext2/ext3 file system\n" \
  950. "\nOptions:" \
  951. "\n -p Automatic repair (no questions)" \
  952. "\n -n Make no changes to the filesystem" \
  953. "\n -y Assume 'yes' to all questions" \
  954. "\n -c Check for bad blocks and add them to the badblock list" \
  955. "\n -f Force checking even if filesystem is marked clean" \
  956. "\n -v Verbose" \
  957. "\n -b superblock Use alternative superblock" \
  958. "\n -B blocksize Force blocksize when looking for superblock" \
  959. "\n -j journal Set location of the external journal" \
  960. "\n -l file Add to badblocks list" \
  961. "\n -L file Set badblocks list" \
  962. */
  963. #define echo_trivial_usage \
  964. IF_FEATURE_FANCY_ECHO("[-neE] ") "[ARG]..."
  965. #define echo_full_usage "\n\n" \
  966. "Print the specified ARGs to stdout" \
  967. IF_FEATURE_FANCY_ECHO( "\n" \
  968. "\nOptions:" \
  969. "\n -n Suppress trailing newline" \
  970. "\n -e Interpret backslash escapes (i.e., \\t=tab)" \
  971. "\n -E Don't interpret backslash escapes (default)" \
  972. )
  973. #define echo_example_usage \
  974. "$ echo \"Erik is cool\"\n" \
  975. "Erik is cool\n" \
  976. IF_FEATURE_FANCY_ECHO("$ echo -e \"Erik\\nis\\ncool\"\n" \
  977. "Erik\n" \
  978. "is\n" \
  979. "cool\n" \
  980. "$ echo \"Erik\\nis\\ncool\"\n" \
  981. "Erik\\nis\\ncool\n")
  982. #define eject_trivial_usage \
  983. "[-t] [-T] [DEVICE]"
  984. #define eject_full_usage "\n\n" \
  985. "Eject DEVICE or default /dev/cdrom\n" \
  986. "\nOptions:" \
  987. IF_FEATURE_EJECT_SCSI( \
  988. "\n -s SCSI device" \
  989. ) \
  990. "\n -t Close tray" \
  991. "\n -T Open/close tray (toggle)" \
  992. #define ed_trivial_usage ""
  993. #define ed_full_usage ""
  994. #define env_trivial_usage \
  995. "[-iu] [-] [name=value]... [PROG ARGS]"
  996. #define env_full_usage "\n\n" \
  997. "Print the current environment or run PROG after setting up\n" \
  998. "the specified environment\n" \
  999. "\nOptions:" \
  1000. "\n -, -i Start with an empty environment" \
  1001. "\n -u Remove variable from the environment" \
  1002. #define ether_wake_trivial_usage \
  1003. "[-b] [-i iface] [-p aa:bb:cc:dd[:ee:ff]] MAC"
  1004. #define ether_wake_full_usage "\n\n" \
  1005. "Send a magic packet to wake up sleeping machines.\n" \
  1006. "MAC must be a station address (00:11:22:33:44:55) or\n" \
  1007. "a hostname with a known 'ethers' entry.\n" \
  1008. "\nOptions:" \
  1009. "\n -b Send wake-up packet to the broadcast address" \
  1010. "\n -i iface Interface to use (default eth0)" \
  1011. "\n -p pass Append four or six byte password PW to the packet" \
  1012. #define expand_trivial_usage \
  1013. "[-i] [-t N] [FILE]..."
  1014. #define expand_full_usage "\n\n" \
  1015. "Convert tabs to spaces, writing to stdout\n" \
  1016. "\nOptions:" \
  1017. IF_FEATURE_EXPAND_LONG_OPTIONS( \
  1018. "\n -i,--initial Don't convert tabs after non blanks" \
  1019. "\n -t,--tabs=N Tabstops every N chars" \
  1020. ) \
  1021. IF_NOT_FEATURE_EXPAND_LONG_OPTIONS( \
  1022. "\n -i Don't convert tabs after non blanks" \
  1023. "\n -t Tabstops every N chars" \
  1024. )
  1025. #define expr_trivial_usage \
  1026. "EXPRESSION"
  1027. #define expr_full_usage "\n\n" \
  1028. "Print the value of EXPRESSION to stdout\n" \
  1029. "\n" \
  1030. "EXPRESSION may be:\n" \
  1031. " ARG1 | ARG2 ARG1 if it is neither null nor 0, otherwise ARG2\n" \
  1032. " ARG1 & ARG2 ARG1 if neither argument is null or 0, otherwise 0\n" \
  1033. " ARG1 < ARG2 1 if ARG1 is less than ARG2, else 0. Similarly:\n" \
  1034. " ARG1 <= ARG2\n" \
  1035. " ARG1 = ARG2\n" \
  1036. " ARG1 != ARG2\n" \
  1037. " ARG1 >= ARG2\n" \
  1038. " ARG1 > ARG2\n" \
  1039. " ARG1 + ARG2 Sum of ARG1 and ARG2. Similarly:\n" \
  1040. " ARG1 - ARG2\n" \
  1041. " ARG1 * ARG2\n" \
  1042. " ARG1 / ARG2\n" \
  1043. " ARG1 % ARG2\n" \
  1044. " STRING : REGEXP Anchored pattern match of REGEXP in STRING\n" \
  1045. " match STRING REGEXP Same as STRING : REGEXP\n" \
  1046. " substr STRING POS LENGTH Substring of STRING, POS counted from 1\n" \
  1047. " index STRING CHARS Index in STRING where any CHARS is found, or 0\n" \
  1048. " length STRING Length of STRING\n" \
  1049. " quote TOKEN Interpret TOKEN as a string, even if\n" \
  1050. " it is a keyword like 'match' or an\n" \
  1051. " operator like '/'\n" \
  1052. " (EXPRESSION) Value of EXPRESSION\n" \
  1053. "\n" \
  1054. "Beware that many operators need to be escaped or quoted for shells.\n" \
  1055. "Comparisons are arithmetic if both ARGs are numbers, else\n" \
  1056. "lexicographical. Pattern matches return the string matched between\n" \
  1057. "\\( and \\) or null; if \\( and \\) are not used, they return the number\n" \
  1058. "of characters matched or 0."
  1059. #define fakeidentd_trivial_usage \
  1060. "[-fiw] [-b ADDR] [STRING]"
  1061. #define fakeidentd_full_usage "\n\n" \
  1062. "Provide fake ident (auth) service\n" \
  1063. "\nOptions:" \
  1064. "\n -f Run in foreground" \
  1065. "\n -i Inetd mode" \
  1066. "\n -w Inetd 'wait' mode" \
  1067. "\n -b ADDR Bind to specified address" \
  1068. "\n STRING Ident answer string (default: nobody)" \
  1069. #define false_trivial_usage \
  1070. ""
  1071. #define false_full_usage "\n\n" \
  1072. "Return an exit code of FALSE (1)"
  1073. #define false_example_usage \
  1074. "$ false\n" \
  1075. "$ echo $?\n" \
  1076. "1\n"
  1077. #define fbsplash_trivial_usage \
  1078. "-s IMGFILE [-c] [-d DEV] [-i INIFILE] [-f CMD]"
  1079. #define fbsplash_full_usage "\n\n" \
  1080. "Options:" \
  1081. "\n -s Image" \
  1082. "\n -c Hide cursor" \
  1083. "\n -d Framebuffer device (default /dev/fb0)" \
  1084. "\n -i Config file (var=value):" \
  1085. "\n BAR_LEFT,BAR_TOP,BAR_WIDTH,BAR_HEIGHT" \
  1086. "\n BAR_R,BAR_G,BAR_B" \
  1087. "\n -f Control pipe (else exit after drawing image)" \
  1088. "\n commands: 'NN' (% for progress bar) or 'exit'" \
  1089. #define fbset_trivial_usage \
  1090. "[OPTIONS] [MODE]"
  1091. #define fbset_full_usage "\n\n" \
  1092. "Show and modify frame buffer settings"
  1093. #define fbset_example_usage \
  1094. "$ fbset\n" \
  1095. "mode \"1024x768-76\"\n" \
  1096. " # D: 78.653 MHz, H: 59.949 kHz, V: 75.694 Hz\n" \
  1097. " geometry 1024 768 1024 768 16\n" \
  1098. " timings 12714 128 32 16 4 128 4\n" \
  1099. " accel false\n" \
  1100. " rgba 5/11,6/5,5/0,0/0\n" \
  1101. "endmode\n"
  1102. #define fdflush_trivial_usage \
  1103. "DEVICE"
  1104. #define fdflush_full_usage "\n\n" \
  1105. "Force floppy disk drive to detect disk change"
  1106. #define fdformat_trivial_usage \
  1107. "[-n] DEVICE"
  1108. #define fdformat_full_usage "\n\n" \
  1109. "Format floppy disk\n" \
  1110. "\nOptions:" \
  1111. "\n -n Don't verify after format" \
  1112. /* Looks like someone forgot to add this to config system */
  1113. #ifndef ENABLE_FEATURE_FDISK_BLKSIZE
  1114. # define ENABLE_FEATURE_FDISK_BLKSIZE 0
  1115. # define IF_FEATURE_FDISK_BLKSIZE(a)
  1116. #endif
  1117. #define fdisk_trivial_usage \
  1118. "[-ul" IF_FEATURE_FDISK_BLKSIZE("s") "] " \
  1119. "[-C CYLINDERS] [-H HEADS] [-S SECTORS] [-b SSZ] DISK"
  1120. #define fdisk_full_usage "\n\n" \
  1121. "Change partition table\n" \
  1122. "\nOptions:" \
  1123. "\n -u Start and End are in sectors (instead of cylinders)" \
  1124. "\n -l Show partition table for each DISK, then exit" \
  1125. IF_FEATURE_FDISK_BLKSIZE( \
  1126. "\n -s Show partition sizes in kb for each DISK, then exit" \
  1127. ) \
  1128. "\n -b 2048 (for certain MO disks) use 2048-byte sectors" \
  1129. "\n -C CYLINDERS Set number of cylinders/heads/sectors" \
  1130. "\n -H HEADS" \
  1131. "\n -S SECTORS" \
  1132. #define blkid_trivial_usage \
  1133. ""
  1134. #define blkid_full_usage "\n\n" \
  1135. "Print UUIDs of all filesystems"
  1136. #define findfs_trivial_usage \
  1137. "LABEL=label or UUID=uuid"
  1138. #define findfs_full_usage "\n\n" \
  1139. "Find a filesystem device based on a label or UUID"
  1140. #define findfs_example_usage \
  1141. "$ findfs LABEL=MyDevice"
  1142. #define find_trivial_usage \
  1143. "[PATH]... [EXPRESSION]"
  1144. #define find_full_usage "\n\n" \
  1145. "Search for files. The default PATH is the current directory,\n" \
  1146. "default EXPRESSION is '-print'\n" \
  1147. "\nEXPRESSION may consist of:" \
  1148. "\n -follow Follow symlinks" \
  1149. IF_FEATURE_FIND_XDEV( \
  1150. "\n -xdev Don't descend directories on other filesystems") \
  1151. IF_FEATURE_FIND_MAXDEPTH( \
  1152. "\n -maxdepth N Descend at most N levels. -maxdepth 0 applies" \
  1153. "\n tests/actions to command line arguments only") \
  1154. "\n -mindepth N Don't act on first N levels" \
  1155. "\n -name PATTERN File name (w/o directory name) matches PATTERN" \
  1156. "\n -iname PATTERN Case insensitive -name" \
  1157. IF_FEATURE_FIND_PATH( \
  1158. "\n -path PATTERN Path matches PATTERN") \
  1159. IF_FEATURE_FIND_REGEX( \
  1160. "\n -regex PATTERN Path matches regex PATTERN") \
  1161. IF_FEATURE_FIND_TYPE( \
  1162. "\n -type X File type is X (X is one of: f,d,l,b,c,...)") \
  1163. IF_FEATURE_FIND_PERM( \
  1164. "\n -perm NNN Permissions match any of (+NNN), all of (-NNN)," \
  1165. "\n or exactly NNN") \
  1166. IF_FEATURE_FIND_MTIME( \
  1167. "\n -mtime DAYS Modified time is greater than (+N), less than (-N)," \
  1168. "\n or exactly N days") \
  1169. IF_FEATURE_FIND_MMIN( \
  1170. "\n -mmin MINS Modified time is greater than (+N), less than (-N)," \
  1171. "\n or exactly N minutes") \
  1172. IF_FEATURE_FIND_NEWER( \
  1173. "\n -newer FILE Modified time is more recent than FILE's") \
  1174. IF_FEATURE_FIND_INUM( \
  1175. "\n -inum N File has inode number N") \
  1176. IF_FEATURE_FIND_USER( \
  1177. "\n -user NAME File is owned by user NAME (numeric user ID allowed)") \
  1178. IF_FEATURE_FIND_GROUP( \
  1179. "\n -group NAME File belongs to group NAME (numeric group ID allowed)") \
  1180. IF_FEATURE_FIND_DEPTH( \
  1181. "\n -depth Process directory name after traversing it") \
  1182. IF_FEATURE_FIND_SIZE( \
  1183. "\n -size N[bck] File size is N (c:bytes,k:kbytes,b:512 bytes(def.))" \
  1184. "\n +/-N: file size is bigger/smaller than N") \
  1185. IF_FEATURE_FIND_LINKS( \
  1186. "\n -links N Number of links is greater than (+N), less than (-N)," \
  1187. "\n or exactly N") \
  1188. "\n -print Print (default and assumed)" \
  1189. IF_FEATURE_FIND_PRINT0( \
  1190. "\n -print0 Delimit output with null characters rather than" \
  1191. "\n newlines") \
  1192. IF_FEATURE_FIND_CONTEXT ( \
  1193. "\n -context File has specified security context") \
  1194. IF_FEATURE_FIND_EXEC( \
  1195. "\n -exec CMD ARG ; Run CMD with all instances of {} replaced by the" \
  1196. "\n matching files") \
  1197. IF_FEATURE_FIND_PRUNE( \
  1198. "\n -prune Stop traversing current subtree") \
  1199. IF_FEATURE_FIND_DELETE( \
  1200. "\n -delete Delete files, turns on -depth option") \
  1201. IF_FEATURE_FIND_PAREN( \
  1202. "\n (EXPR) Group an expression") \
  1203. #define find_example_usage \
  1204. "$ find / -name passwd\n" \
  1205. "/etc/passwd\n"
  1206. #define flash_lock_trivial_usage \
  1207. "MTD_DEVICE OFFSET SECTORS"
  1208. #define flash_lock_full_usage "\n\n" \
  1209. "Lock part or all of an MTD device. If SECTORS is -1, then all sectors\n" \
  1210. "will be locked, regardless of the value of OFFSET"
  1211. #define flash_unlock_trivial_usage \
  1212. "MTD_DEVICE"
  1213. #define flash_unlock_full_usage "\n\n" \
  1214. "Unlock an MTD device"
  1215. #define flash_eraseall_trivial_usage \
  1216. "[-jq] MTD_DEVICE"
  1217. #define flash_eraseall_full_usage "\n\n" \
  1218. "Erase an MTD device\n" \
  1219. "\nOptions:" \
  1220. "\n -j Format the device for jffs2" \
  1221. "\n -q Don't display progress messages" \
  1222. #define flashcp_trivial_usage \
  1223. "-v FILE MTD_DEVICE"
  1224. #define flashcp_full_usage "\n\n" \
  1225. "Copy an image to MTD device\n" \
  1226. "\nOptions:" \
  1227. "\n -v Verbose" \
  1228. #define flock_trivial_usage \
  1229. "[-sxun] FD|{FILE [-c] PROG ARGS}"
  1230. #define flock_full_usage "\n\n" \
  1231. "[Un]lock file descriptor, or lock FILE and run PROG\n" \
  1232. "\nOptions:" \
  1233. "\n -s Shared lock" \
  1234. "\n -x Exclusive lock (default)" \
  1235. "\n -u Unlock FD" \
  1236. "\n -n Fail rather than wait" \
  1237. #define fold_trivial_usage \
  1238. "[-bs] [-w WIDTH] [FILE]..."
  1239. #define fold_full_usage "\n\n" \
  1240. "Wrap input lines in each FILE (or stdin), writing to stdout\n" \
  1241. "\nOptions:" \
  1242. "\n -b Count bytes rather than columns" \
  1243. "\n -s Break at spaces" \
  1244. "\n -w Use WIDTH columns instead of 80" \
  1245. #define free_trivial_usage \
  1246. ""
  1247. #define free_full_usage "\n\n" \
  1248. "Display the amount of free and used system memory"
  1249. #define free_example_usage \
  1250. "$ free\n" \
  1251. " total used free shared buffers\n" \
  1252. " Mem: 257628 248724 8904 59644 93124\n" \
  1253. " Swap: 128516 8404 120112\n" \
  1254. "Total: 386144 257128 129016\n" \
  1255. #define freeramdisk_trivial_usage \
  1256. "DEVICE"
  1257. #define freeramdisk_full_usage "\n\n" \
  1258. "Free all memory used by the specified ramdisk"
  1259. #define freeramdisk_example_usage \
  1260. "$ freeramdisk /dev/ram2\n"
  1261. #define fsck_trivial_usage \
  1262. "[-ANPRTV] [-C FD] [-t FSTYPE] [FS_OPTS] [BLOCKDEV]..."
  1263. #define fsck_full_usage "\n\n" \
  1264. "Check and repair filesystems\n" \
  1265. "\nOptions:" \
  1266. "\n -A Walk /etc/fstab and check all filesystems" \
  1267. "\n -N Don't execute, just show what would be done" \
  1268. "\n -P With -A, check filesystems in parallel" \
  1269. "\n -R With -A, skip the root filesystem" \
  1270. "\n -T Don't show title on startup" \
  1271. "\n -V Verbose" \
  1272. "\n -C n Write status information to specified filedescriptor" \
  1273. "\n -t TYPE List of filesystem types to check" \
  1274. #define fsck_minix_trivial_usage \
  1275. "[-larvsmf] BLOCKDEV"
  1276. #define fsck_minix_full_usage "\n\n" \
  1277. "Check MINIX filesystem\n" \
  1278. "\nOptions:" \
  1279. "\n -l List all filenames" \
  1280. "\n -r Perform interactive repairs" \
  1281. "\n -a Perform automatic repairs" \
  1282. "\n -v Verbose" \
  1283. "\n -s Output superblock information" \
  1284. "\n -m Show \"mode not cleared\" warnings" \
  1285. "\n -f Force file system check" \
  1286. #define ftpd_trivial_usage \
  1287. "[-wvS] [-t N] [-T N] [DIR]"
  1288. #define ftpd_full_usage "\n\n" \
  1289. "Anonymous FTP server\n" \
  1290. "\n" \
  1291. "ftpd should be used as an inetd service.\n" \
  1292. "ftpd's line for inetd.conf:\n" \
  1293. " 21 stream tcp nowait root ftpd ftpd /files/to/serve\n" \
  1294. "It also can be ran from tcpsvd:\n" \
  1295. " tcpsvd -vE 0.0.0.0 21 ftpd /files/to/serve\n" \
  1296. "\nOptions:" \
  1297. "\n -w Allow upload" \
  1298. "\n -v Log to stderr" \
  1299. "\n -S Log to syslog" \
  1300. "\n -t,-T Idle and absolute timeouts" \
  1301. "\n DIR Change root to this directory" \
  1302. #define ftpget_trivial_usage \
  1303. "[OPTIONS] HOST [LOCAL_FILE] REMOTE_FILE"
  1304. #define ftpget_full_usage "\n\n" \
  1305. "Retrieve a remote file via FTP\n" \
  1306. "\nOptions:" \
  1307. IF_FEATURE_FTPGETPUT_LONG_OPTIONS( \
  1308. "\n -c,--continue Continue previous transfer" \
  1309. "\n -v,--verbose Verbose" \
  1310. "\n -u,--username Username" \
  1311. "\n -p,--password Password" \
  1312. "\n -P,--port Port number" \
  1313. ) \
  1314. IF_NOT_FEATURE_FTPGETPUT_LONG_OPTIONS( \
  1315. "\n -c Continue previous transfer" \
  1316. "\n -v Verbose" \
  1317. "\n -u Username" \
  1318. "\n -p Password" \
  1319. "\n -P Port number" \
  1320. )
  1321. #define ftpput_trivial_usage \
  1322. "[OPTIONS] HOST [REMOTE_FILE] LOCAL_FILE"
  1323. #define ftpput_full_usage "\n\n" \
  1324. "Store a local file on a remote machine via FTP\n" \
  1325. "\nOptions:" \
  1326. IF_FEATURE_FTPGETPUT_LONG_OPTIONS( \
  1327. "\n -v,--verbose Verbose" \
  1328. "\n -u,--username Username" \
  1329. "\n -p,--password Password" \
  1330. "\n -P,--port Port number" \
  1331. ) \
  1332. IF_NOT_FEATURE_FTPGETPUT_LONG_OPTIONS( \
  1333. "\n -v Verbose" \
  1334. "\n -u Username" \
  1335. "\n -p Password" \
  1336. "\n -P Port number" \
  1337. )
  1338. #define fuser_trivial_usage \
  1339. "[OPTIONS] FILE or PORT/PROTO"
  1340. #define fuser_full_usage "\n\n" \
  1341. "Find processes which use FILEs or PORTs\n" \
  1342. "\nOptions:" \
  1343. "\n -m Find processes which use same fs as FILEs" \
  1344. "\n -4 Search only IPv4 space" \
  1345. "\n -6 Search only IPv6 space" \
  1346. "\n -s Silent: just exit with 0 if any processes are found" \
  1347. "\n -k Kill found processes (otherwise display PIDs)" \
  1348. "\n -SIGNAL Signal to send (default: TERM)" \
  1349. #define getenforce_trivial_usage NOUSAGE_STR
  1350. #define getenforce_full_usage ""
  1351. #define getopt_trivial_usage \
  1352. "[OPTIONS]"
  1353. #define getopt_full_usage "\n\n" \
  1354. "Options:" \
  1355. IF_LONG_OPTS( \
  1356. "\n -a,--alternative Allow long options starting with single -" \
  1357. "\n -l,--longoptions=longopts Long options to be recognized" \
  1358. "\n -n,--name=progname The name under which errors are reported" \
  1359. "\n -o,--options=optstring Short options to be recognized" \
  1360. "\n -q,--quiet Disable error reporting by getopt(3)" \
  1361. "\n -Q,--quiet-output No normal output" \
  1362. "\n -s,--shell=shell Set shell quoting conventions" \
  1363. "\n -T,--test Test for getopt(1) version" \
  1364. "\n -u,--unquoted Don't quote the output" \
  1365. ) \
  1366. IF_NOT_LONG_OPTS( \
  1367. "\n -a Allow long options starting with single -" \
  1368. "\n -l longopts Long options to be recognized" \
  1369. "\n -n progname The name under which errors are reported" \
  1370. "\n -o optstring Short options to be recognized" \
  1371. "\n -q Disable error reporting by getopt(3)" \
  1372. "\n -Q No normal output" \
  1373. "\n -s shell Set shell quoting conventions" \
  1374. "\n -T Test for getopt(1) version" \
  1375. "\n -u Don't quote the output" \
  1376. )
  1377. #define getopt_example_usage \
  1378. "$ cat getopt.test\n" \
  1379. "#!/bin/sh\n" \
  1380. "GETOPT=`getopt -o ab:c:: --long a-long,b-long:,c-long:: \\\n" \
  1381. " -n 'example.busybox' -- \"$@\"`\n" \
  1382. "if [ $? != 0 ]; then exit 1; fi\n" \
  1383. "eval set -- \"$GETOPT\"\n" \
  1384. "while true; do\n" \
  1385. " case $1 in\n" \
  1386. " -a|--a-long) echo \"Option a\"; shift;;\n" \
  1387. " -b|--b-long) echo \"Option b, argument '$2'\"; shift 2;;\n" \
  1388. " -c|--c-long)\n" \
  1389. " case \"$2\" in\n" \
  1390. " \"\") echo \"Option c, no argument\"; shift 2;;\n" \
  1391. " *) echo \"Option c, argument '$2'\"; shift 2;;\n" \
  1392. " esac;;\n" \
  1393. " --) shift; break;;\n" \
  1394. " *) echo \"Internal error!\"; exit 1;;\n" \
  1395. " esac\n" \
  1396. "done\n"
  1397. #define getsebool_trivial_usage \
  1398. "-a or getsebool boolean..."
  1399. #define getsebool_full_usage "\n\n" \
  1400. " -a Show all selinux booleans"
  1401. #define getty_trivial_usage \
  1402. "[OPTIONS] BAUD_RATE TTY [TERMTYPE]"
  1403. #define getty_full_usage "\n\n" \
  1404. "Open a tty, prompt for a login name, then invoke /bin/login\n" \
  1405. "\nOptions:" \
  1406. "\n -h Enable hardware (RTS/CTS) flow control" \
  1407. "\n -i Don't display /etc/issue before running login" \
  1408. "\n -L Local line, don't do carrier detect" \
  1409. "\n -m Get baud rate from modem's CONNECT status message" \
  1410. "\n -w Wait for a CR or LF before sending /etc/issue" \
  1411. "\n -n Don't prompt the user for a login name" \
  1412. "\n -f ISSUE_FILE Display ISSUE_FILE instead of /etc/issue" \
  1413. "\n -l LOGIN Invoke LOGIN instead of /bin/login" \
  1414. "\n -t SEC Terminate after SEC if no username is read" \
  1415. "\n -I INITSTR Send INITSTR before anything else" \
  1416. "\n -H HOST Log HOST into the utmp file as the hostname" \
  1417. #define grep_trivial_usage \
  1418. "[-HhnlLoqvsriw" \
  1419. "F" \
  1420. IF_FEATURE_GREP_EGREP_ALIAS("E") \
  1421. IF_EXTRA_COMPAT("z") \
  1422. "] [-m N] " \
  1423. IF_FEATURE_GREP_CONTEXT("[-A/B/C N] ") \
  1424. "PATTERN/-e PATTERN.../-f FILE [FILE]..."
  1425. #define grep_full_usage "\n\n" \
  1426. "Search for PATTERN in FILEs (or stdin)\n" \
  1427. "\nOptions:" \
  1428. "\n -H Add 'filename:' prefix" \
  1429. "\n -h Do not add 'filename:' prefix" \
  1430. "\n -n Add 'line_no:' prefix" \
  1431. "\n -l Show only names of files that match" \
  1432. "\n -L Show only names of files that don't match" \
  1433. "\n -c Show only count of matching lines" \
  1434. "\n -o Show only the matching part of line" \
  1435. "\n -q Quiet. Return 0 if PATTERN is found, 1 otherwise" \
  1436. "\n -v Select non-matching lines" \
  1437. "\n -s Suppress open and read errors" \
  1438. "\n -r Recurse" \
  1439. "\n -i Ignore case" \
  1440. "\n -w Match whole words only" \
  1441. "\n -F PATTERN is a literal (not regexp)" \
  1442. IF_FEATURE_GREP_EGREP_ALIAS( \
  1443. "\n -E PATTERN is an extended regexp" \
  1444. ) \
  1445. IF_EXTRA_COMPAT( \
  1446. "\n -z Input is NUL terminated" \
  1447. ) \
  1448. "\n -m N Match up to N times per file" \
  1449. IF_FEATURE_GREP_CONTEXT( \
  1450. "\n -A N Print N lines of trailing context" \
  1451. "\n -B N Print N lines of leading context" \
  1452. "\n -C N Same as '-A N -B N'" \
  1453. ) \
  1454. "\n -e PTRN Pattern to match" \
  1455. "\n -f FILE Read pattern from file" \
  1456. #define grep_example_usage \
  1457. "$ grep root /etc/passwd\n" \
  1458. "root:x:0:0:root:/root:/bin/bash\n" \
  1459. "$ grep ^[rR]oo. /etc/passwd\n" \
  1460. "root:x:0:0:root:/root:/bin/bash\n"
  1461. #define egrep_trivial_usage NOUSAGE_STR
  1462. #define egrep_full_usage ""
  1463. #define fgrep_trivial_usage NOUSAGE_STR
  1464. #define fgrep_full_usage ""
  1465. #define gunzip_trivial_usage \
  1466. "[OPTIONS] [FILE]..."
  1467. #define gunzip_full_usage "\n\n" \
  1468. "Uncompress FILEs (or stdin)\n" \
  1469. "\nOptions:" \
  1470. "\n -c Write to stdout" \
  1471. "\n -f Force" \
  1472. "\n -t Test file integrity" \
  1473. #define gunzip_example_usage \
  1474. "$ ls -la /tmp/BusyBox*\n" \
  1475. "-rw-rw-r-- 1 andersen andersen 557009 Apr 11 10:55 /tmp/BusyBox-0.43.tar.gz\n" \
  1476. "$ gunzip /tmp/BusyBox-0.43.tar.gz\n" \
  1477. "$ ls -la /tmp/BusyBox*\n" \
  1478. "-rw-rw-r-- 1 andersen andersen 1761280 Apr 14 17:47 /tmp/BusyBox-0.43.tar\n"
  1479. #define gzip_trivial_usage \
  1480. "[OPTIONS] [FILE]..."
  1481. #define gzip_full_usage "\n\n" \
  1482. "Compress FILEs (or stdin)\n" \
  1483. "\nOptions:" \
  1484. "\n -c Write to stdout" \
  1485. "\n -d Decompress" \
  1486. "\n -f Force" \
  1487. #define gzip_example_usage \
  1488. "$ ls -la /tmp/busybox*\n" \
  1489. "-rw-rw-r-- 1 andersen andersen 1761280 Apr 14 17:47 /tmp/busybox.tar\n" \
  1490. "$ gzip /tmp/busybox.tar\n" \
  1491. "$ ls -la /tmp/busybox*\n" \
  1492. "-rw-rw-r-- 1 andersen andersen 554058 Apr 14 17:49 /tmp/busybox.tar.gz\n"
  1493. #define halt_trivial_usage \
  1494. "[-d DELAY] [-n] [-f]" IF_FEATURE_WTMP(" [-w]")
  1495. #define halt_full_usage "\n\n" \
  1496. "Halt the system\n" \
  1497. "\nOptions:" \
  1498. "\n -d Delay interval for halting" \
  1499. "\n -n No call to sync()" \
  1500. "\n -f Force halt (don't go through init)" \
  1501. IF_FEATURE_WTMP( \
  1502. "\n -w Only write a wtmp record" \
  1503. )
  1504. #define hdparm_trivial_usage \
  1505. "[OPTIONS] [DEVICE]"
  1506. #define hdparm_full_usage "\n\n" \
  1507. "Options:" \
  1508. "\n -a Get/set fs readahead" \
  1509. "\n -A Set drive read-lookahead flag (0/1)" \
  1510. "\n -b Get/set bus state (0 == off, 1 == on, 2 == tristate)" \
  1511. "\n -B Set Advanced Power Management setting (1-255)" \
  1512. "\n -c Get/set IDE 32-bit IO setting" \
  1513. "\n -C Check IDE power mode status" \
  1514. IF_FEATURE_HDPARM_HDIO_GETSET_DMA( \
  1515. "\n -d Get/set using_dma flag") \
  1516. "\n -D Enable/disable drive defect-mgmt" \
  1517. "\n -f Flush buffer cache for device on exit" \
  1518. "\n -g Display drive geometry" \
  1519. "\n -h Display terse usage information" \
  1520. IF_FEATURE_HDPARM_GET_IDENTITY( \
  1521. "\n -i Display drive identification") \
  1522. IF_FEATURE_HDPARM_GET_IDENTITY( \
  1523. "\n -I Detailed/current information directly from drive") \
  1524. "\n -k Get/set keep_settings_over_reset flag (0/1)" \
  1525. "\n -K Set drive keep_features_over_reset flag (0/1)" \
  1526. "\n -L Set drive doorlock (0/1) (removable harddisks only)" \
  1527. "\n -m Get/set multiple sector count" \
  1528. "\n -n Get/set ignore-write-errors flag (0/1)" \
  1529. "\n -p Set PIO mode on IDE interface chipset (0,1,2,3,4,...)" \
  1530. "\n -P Set drive prefetch count" \
  1531. /* "\n -q Change next setting quietly" - not supported ib bbox */ \
  1532. "\n -Q Get/set DMA tagged-queuing depth (if supported)" \
  1533. "\n -r Get/set readonly flag (DANGEROUS to set)" \
  1534. IF_FEATURE_HDPARM_HDIO_SCAN_HWIF( \
  1535. "\n -R Register an IDE interface (DANGEROUS)") \
  1536. "\n -S Set standby (spindown) timeout" \
  1537. "\n -t Perform device read timings" \
  1538. "\n -T Perform cache read timings" \
  1539. "\n -u Get/set unmaskirq flag (0/1)" \
  1540. IF_FEATURE_HDPARM_HDIO_UNREGISTER_HWIF( \
  1541. "\n -U Unregister an IDE interface (DANGEROUS)") \
  1542. "\n -v Defaults; same as -mcudkrag for IDE drives" \
  1543. "\n -V Display program version and exit immediately" \
  1544. IF_FEATURE_HDPARM_HDIO_DRIVE_RESET( \
  1545. "\n -w Perform device reset (DANGEROUS)") \
  1546. "\n -W Set drive write-caching flag (0/1) (DANGEROUS)" \
  1547. IF_FEATURE_HDPARM_HDIO_TRISTATE_HWIF( \
  1548. "\n -x Tristate device for hotswap (0/1) (DANGEROUS)") \
  1549. "\n -X Set IDE xfer mode (DANGEROUS)" \
  1550. "\n -y Put IDE drive in standby mode" \
  1551. "\n -Y Put IDE drive to sleep" \
  1552. "\n -Z Disable Seagate auto-powersaving mode" \
  1553. "\n -z Reread partition table" \
  1554. #define head_trivial_usage \
  1555. "[OPTIONS] [FILE]..."
  1556. #define head_full_usage "\n\n" \
  1557. "Print first 10 lines of each FILE (or stdin) to stdout.\n" \
  1558. "With more than one FILE, precede each with a filename header.\n" \
  1559. "\nOptions:" \
  1560. "\n -n N[kbm] Print first N lines" \
  1561. IF_FEATURE_FANCY_HEAD( \
  1562. "\n -c N[kbm] Print first N bytes" \
  1563. "\n -q Never print headers" \
  1564. "\n -v Always print headers" \
  1565. ) \
  1566. "\n" \
  1567. "\nN may be suffixed by k (x1024), b (x512), or m (x1024^2)." \
  1568. #define head_example_usage \
  1569. "$ head -n 2 /etc/passwd\n" \
  1570. "root:x:0:0:root:/root:/bin/bash\n" \
  1571. "daemon:x:1:1:daemon:/usr/sbin:/bin/sh\n"
  1572. #define tail_trivial_usage \
  1573. "[OPTIONS] [FILE]..."
  1574. #define tail_full_usage "\n\n" \
  1575. "Print last 10 lines of each FILE (or stdin) to stdout.\n" \
  1576. "With more than one FILE, precede each with a filename header.\n" \
  1577. "\nOptions:" \
  1578. "\n -f Print data as file grows" \
  1579. IF_FEATURE_FANCY_TAIL( \
  1580. "\n -s SECONDS Wait SECONDS between reads with -f" \
  1581. ) \
  1582. "\n -n N[kbm] Print last N lines" \
  1583. IF_FEATURE_FANCY_TAIL( \
  1584. "\n -c N[kbm] Print last N bytes" \
  1585. "\n -q Never print headers" \
  1586. "\n -v Always print headers" \
  1587. "\n" \
  1588. "\nN may be suffixed by k (x1024), b (x512), or m (x1024^2)." \
  1589. "\nIf N starts with a '+', output begins with the Nth item from the start" \
  1590. "\nof each file, not from the end." \
  1591. ) \
  1592. #define tail_example_usage \
  1593. "$ tail -n 1 /etc/resolv.conf\n" \
  1594. "nameserver 10.0.0.1\n"
  1595. #define hexdump_trivial_usage \
  1596. "[-bcCdefnosvx" IF_FEATURE_HEXDUMP_REVERSE("R") "] [FILE]..."
  1597. #define hexdump_full_usage "\n\n" \
  1598. "Display FILEs (or stdin) in a user specified format\n" \
  1599. "\nOptions:" \
  1600. "\n -b One-byte octal display" \
  1601. "\n -c One-byte character display" \
  1602. "\n -C Canonical hex+ASCII, 16 bytes per line" \
  1603. "\n -d Two-byte decimal display" \
  1604. "\n -e FORMAT STRING" \
  1605. "\n -f FORMAT FILE" \
  1606. "\n -n LENGTH Interpret only LENGTH bytes of input" \
  1607. "\n -o Two-byte octal display" \
  1608. "\n -s OFFSET Skip OFFSET bytes" \
  1609. "\n -v Display all input data" \
  1610. "\n -x Two-byte hexadecimal display" \
  1611. IF_FEATURE_HEXDUMP_REVERSE( \
  1612. "\n -R Reverse of 'hexdump -Cv'") \
  1613. #define hd_trivial_usage \
  1614. "FILE..."
  1615. #define hd_full_usage "\n\n" \
  1616. "hd is an alias for hexdump -C"
  1617. #define hostid_trivial_usage \
  1618. ""
  1619. #define hostid_full_usage "\n\n" \
  1620. "Print out a unique 32-bit identifier for the machine"
  1621. #define hostname_trivial_usage \
  1622. "[OPTIONS] [HOSTNAME | -F FILE]"
  1623. #define hostname_full_usage "\n\n" \
  1624. "Get or set hostname or DNS domain name\n" \
  1625. "\nOptions:" \
  1626. "\n -s Short" \
  1627. "\n -i Addresses for the hostname" \
  1628. "\n -d DNS domain name" \
  1629. "\n -f Fully qualified domain name" \
  1630. "\n -F FILE Use FILE's content as hostname" \
  1631. #define hostname_example_usage \
  1632. "$ hostname\n" \
  1633. "sage\n"
  1634. #define dnsdomainname_trivial_usage NOUSAGE_STR
  1635. #define dnsdomainname_full_usage ""
  1636. #define httpd_trivial_usage \
  1637. "[-ifv[v]]" \
  1638. " [-c CONFFILE]" \
  1639. " [-p [IP:]PORT]" \
  1640. IF_FEATURE_HTTPD_SETUID(" [-u USER[:GRP]]") \
  1641. IF_FEATURE_HTTPD_BASIC_AUTH(" [-r REALM]") \
  1642. " [-h HOME]\n" \
  1643. "or httpd -d/-e" IF_FEATURE_HTTPD_AUTH_MD5("/-m") " STRING"
  1644. #define httpd_full_usage "\n\n" \
  1645. "Listen for incoming HTTP requests\n" \
  1646. "\nOptions:" \
  1647. "\n -i Inetd mode" \
  1648. "\n -f Don't daemonize" \
  1649. "\n -v[v] Verbose" \
  1650. "\n -p [IP:]PORT Bind to ip:port (default *:80)" \
  1651. IF_FEATURE_HTTPD_SETUID( \
  1652. "\n -u USER[:GRP] Set uid/gid after binding to port") \
  1653. IF_FEATURE_HTTPD_BASIC_AUTH( \
  1654. "\n -r REALM Authentication Realm for Basic Authentication") \
  1655. "\n -h HOME Home directory (default .)" \
  1656. "\n -c FILE Configuration file (default {/etc,HOME}/httpd.conf)" \
  1657. IF_FEATURE_HTTPD_AUTH_MD5( \
  1658. "\n -m STRING MD5 crypt STRING") \
  1659. "\n -e STRING HTML encode STRING" \
  1660. "\n -d STRING URL decode STRING" \
  1661. #define hwclock_trivial_usage \
  1662. IF_FEATURE_HWCLOCK_LONG_OPTIONS( \
  1663. "[-r|--show] [-s|--hctosys] [-w|--systohc]" \
  1664. " [-l|--localtime] [-u|--utc]" \
  1665. " [-f FILE]" \
  1666. ) \
  1667. IF_NOT_FEATURE_HWCLOCK_LONG_OPTIONS( \
  1668. "[-r] [-s] [-w] [-l] [-u] [-f FILE]" \
  1669. )
  1670. #define hwclock_full_usage "\n\n" \
  1671. "Query and set hardware clock (RTC)\n" \
  1672. "\nOptions:" \
  1673. "\n -r Show hardware clock time" \
  1674. "\n -s Set system time from hardware clock" \
  1675. "\n -w Set hardware clock to system time" \
  1676. "\n -u Hardware clock is in UTC" \
  1677. "\n -l Hardware clock is in local time" \
  1678. "\n -f FILE Use specified device (e.g. /dev/rtc2)" \
  1679. #define id_trivial_usage \
  1680. "[OPTIONS] [USER]"
  1681. #define id_full_usage "\n\n" \
  1682. "Print information about USER or the current user\n" \
  1683. "\nOptions:" \
  1684. IF_SELINUX( \
  1685. "\n -Z Print the security context" \
  1686. ) \
  1687. "\n -u Print user ID" \
  1688. "\n -g Print group ID" \
  1689. "\n -G Print supplementary group IDs" \
  1690. "\n -n Print name instead of a number" \
  1691. "\n -r Print real user ID instead of effective ID" \
  1692. #define id_example_usage \
  1693. "$ id\n" \
  1694. "uid=1000(andersen) gid=1000(andersen)\n"
  1695. #define ifconfig_trivial_usage \
  1696. IF_FEATURE_IFCONFIG_STATUS("[-a]") " interface [address]"
  1697. #define ifconfig_full_usage "\n\n" \
  1698. "Configure a network interface\n" \
  1699. "\nOptions:" \
  1700. "\n" \
  1701. IF_FEATURE_IPV6( \
  1702. " [add ADDRESS[/PREFIXLEN]]\n") \
  1703. IF_FEATURE_IPV6( \
  1704. " [del ADDRESS[/PREFIXLEN]]\n") \
  1705. " [[-]broadcast [ADDRESS]] [[-]pointopoint [ADDRESS]]\n" \
  1706. " [netmask ADDRESS] [dstaddr ADDRESS]\n" \
  1707. IF_FEATURE_IFCONFIG_SLIP( \
  1708. " [outfill NN] [keepalive NN]\n") \
  1709. " " IF_FEATURE_IFCONFIG_HW("[hw ether" IF_FEATURE_HWIB("|infiniband")" ADDRESS] ") "[metric NN] [mtu NN]\n" \
  1710. " [[-]trailers] [[-]arp] [[-]allmulti]\n" \
  1711. " [multicast] [[-]promisc] [txqueuelen NN] [[-]dynamic]\n" \
  1712. IF_FEATURE_IFCONFIG_MEMSTART_IOADDR_IRQ( \
  1713. " [mem_start NN] [io_addr NN] [irq NN]\n") \
  1714. " [up|down] ..."
  1715. #define ifenslave_trivial_usage \
  1716. "[-cdf] MASTER_IFACE SLAVE_IFACE..."
  1717. #define ifenslave_full_usage "\n\n" \
  1718. "Configure network interfaces for parallel routing\n" \
  1719. "\nOptions:" \
  1720. "\n -c, --change-active Change active slave" \
  1721. "\n -d, --detach Remove slave interface from bonding device" \
  1722. "\n -f, --force Force, even if interface is not Ethernet" \
  1723. /* "\n -r, --receive-slave Create a receive-only slave" */
  1724. #define ifenslave_example_usage \
  1725. "To create a bond device, simply follow these three steps:\n" \
  1726. "- ensure that the required drivers are properly loaded:\n" \
  1727. " # modprobe bonding ; modprobe <3c59x|eepro100|pcnet32|tulip|...>\n" \
  1728. "- assign an IP address to the bond device:\n" \
  1729. " # ifconfig bond0 <addr> netmask <mask> broadcast <bcast>\n" \
  1730. "- attach all the interfaces you need to the bond device:\n" \
  1731. " # ifenslave bond0 eth0 eth1 eth2\n" \
  1732. " If bond0 didn't have a MAC address, it will take eth0's. Then, all\n" \
  1733. " interfaces attached AFTER this assignment will get the same MAC addr.\n\n" \
  1734. " To detach a dead interface without setting the bond device down:\n" \
  1735. " # ifenslave -d bond0 eth1\n\n" \
  1736. " To set the bond device down and automatically release all the slaves:\n" \
  1737. " # ifconfig bond0 down\n\n" \
  1738. " To change active slave:\n" \
  1739. " # ifenslave -c bond0 eth0\n" \
  1740. #define ifplugd_trivial_usage \
  1741. "[OPTIONS]"
  1742. #define ifplugd_full_usage "\n\n" \
  1743. "Network interface plug detection daemon\n" \
  1744. "\nOptions:" \
  1745. "\n -n Don't daemonize" \
  1746. "\n -s Don't log to syslog" \
  1747. "\n -i IFACE Interface" \
  1748. "\n -f/-F Treat link detection error as link down/link up" \
  1749. "\n (otherwise exit on error)" \
  1750. "\n -a Don't up interface at each link probe" \
  1751. "\n -M Monitor creation/destruction of interface" \
  1752. "\n (otherwise it must exist)" \
  1753. "\n -r PROG Script to run" \
  1754. "\n -x ARG Extra argument for script" \
  1755. "\n -I Don't exit on nonzero exit code from script" \
  1756. "\n -p Don't run script on daemon startup" \
  1757. "\n -q Don't run script on daemon quit" \
  1758. "\n -l Run script on startup even if no cable is detected" \
  1759. "\n -t SECS Poll time in seconds" \
  1760. "\n -u SECS Delay before running script after link up" \
  1761. "\n -d SECS Delay after link down" \
  1762. "\n -m MODE API mode (mii, priv, ethtool, wlan, iff, auto)" \
  1763. "\n -k Kill running daemon" \
  1764. #define ifup_trivial_usage \
  1765. "[-ain"IF_FEATURE_IFUPDOWN_MAPPING("m")"vf] IFACE..."
  1766. #define ifup_full_usage "\n\n" \
  1767. "Options:" \
  1768. "\n -a De/configure all interfaces automatically" \
  1769. "\n -i FILE Use FILE for interface definitions" \
  1770. "\n -n Print out what would happen, but don't do it" \
  1771. IF_FEATURE_IFUPDOWN_MAPPING( \
  1772. "\n (note: doesn't disable mappings)" \
  1773. "\n -m Don't run any mappings" \
  1774. ) \
  1775. "\n -v Print out what would happen before doing it" \
  1776. "\n -f Force de/configuration" \
  1777. #define ifdown_trivial_usage \
  1778. "[-ain"IF_FEATURE_IFUPDOWN_MAPPING("m")"vf] ifaces..."
  1779. #define ifdown_full_usage "\n\n" \
  1780. "Options:" \
  1781. "\n -a De/configure all interfaces automatically" \
  1782. "\n -i FILE Use FILE for interface definitions" \
  1783. "\n -n Print out what would happen, but don't do it" \
  1784. IF_FEATURE_IFUPDOWN_MAPPING( \
  1785. "\n (note: doesn't disable mappings)" \
  1786. "\n -m Don't run any mappings" \
  1787. ) \
  1788. "\n -v Print out what would happen before doing it" \
  1789. "\n -f Force de/configuration" \
  1790. #define inetd_trivial_usage \
  1791. "[-fe] [-q N] [-R N] [CONFFILE]"
  1792. #define inetd_full_usage "\n\n" \
  1793. "Listen for network connections and launch programs\n" \
  1794. "\nOptions:" \
  1795. "\n -f Run in foreground" \
  1796. "\n -e Log to stderr" \
  1797. "\n -q N Socket listen queue (default: 128)" \
  1798. "\n -R N Pause services after N connects/min" \
  1799. "\n (default: 0 - disabled)" \
  1800. #define init_trivial_usage \
  1801. ""
  1802. #define init_full_usage "\n\n" \
  1803. "Init is the parent of all processes"
  1804. #define init_notes_usage \
  1805. "This version of init is designed to be run only by the kernel.\n" \
  1806. "\n" \
  1807. "BusyBox init doesn't support multiple runlevels. The runlevels field of\n" \
  1808. "the /etc/inittab file is completely ignored by BusyBox init. If you want\n" \
  1809. "runlevels, use sysvinit.\n" \
  1810. "\n" \
  1811. "BusyBox init works just fine without an inittab. If no inittab is found,\n" \
  1812. "it has the following default behavior:\n" \
  1813. "\n" \
  1814. " ::sysinit:/etc/init.d/rcS\n" \
  1815. " ::askfirst:/bin/sh\n" \
  1816. " ::ctrlaltdel:/sbin/reboot\n" \
  1817. " ::shutdown:/sbin/swapoff -a\n" \
  1818. " ::shutdown:/bin/umount -a -r\n" \
  1819. " ::restart:/sbin/init\n" \
  1820. "\n" \
  1821. "if it detects that /dev/console is _not_ a serial console, it will also run:\n" \
  1822. "\n" \
  1823. " tty2::askfirst:/bin/sh\n" \
  1824. " tty3::askfirst:/bin/sh\n" \
  1825. " tty4::askfirst:/bin/sh\n" \
  1826. "\n" \
  1827. "If you choose to use an /etc/inittab file, the inittab entry format is as follows:\n" \
  1828. "\n" \
  1829. " <id>:<runlevels>:<action>:<process>\n" \
  1830. "\n" \
  1831. " <id>:\n" \
  1832. "\n" \
  1833. " WARNING: This field has a non-traditional meaning for BusyBox init!\n" \
  1834. " The id field is used by BusyBox init to specify the controlling tty for\n" \
  1835. " the specified process to run on. The contents of this field are\n" \
  1836. " appended to \"/dev/\" and used as-is. There is no need for this field to\n" \
  1837. " be unique, although if it isn't you may have strange results. If this\n" \
  1838. " field is left blank, the controlling tty is set to the console. Also\n" \
  1839. " note that if BusyBox detects that a serial console is in use, then only\n" \
  1840. " entries whose controlling tty is either the serial console or /dev/null\n" \
  1841. " will be run. BusyBox init does nothing with utmp. We don't need no\n" \
  1842. " stinkin' utmp.\n" \
  1843. "\n" \
  1844. " <runlevels>:\n" \
  1845. "\n" \
  1846. " The runlevels field is completely ignored.\n" \
  1847. "\n" \
  1848. " <action>:\n" \
  1849. "\n" \
  1850. " Valid actions include: sysinit, respawn, askfirst, wait,\n" \
  1851. " once, restart, ctrlaltdel, and shutdown.\n" \
  1852. "\n" \
  1853. " The available actions can be classified into two groups: actions\n" \
  1854. " that are run only once, and actions that are re-run when the specified\n" \
  1855. " process exits.\n" \
  1856. "\n" \
  1857. " Run only-once actions:\n" \
  1858. "\n" \
  1859. " 'sysinit' is the first item run on boot. init waits until all\n" \
  1860. " sysinit actions are completed before continuing. Following the\n" \
  1861. " completion of all sysinit actions, all 'wait' actions are run.\n" \
  1862. " 'wait' actions, like 'sysinit' actions, cause init to wait until\n" \
  1863. " the specified task completes. 'once' actions are asynchronous,\n" \
  1864. " therefore, init does not wait for them to complete. 'restart' is\n" \
  1865. " the action taken to restart the init process. By default this should\n" \
  1866. " simply run /sbin/init, but can be a script which runs pivot_root or it\n" \
  1867. " can do all sorts of other interesting things. The 'ctrlaltdel' init\n" \
  1868. " actions are run when the system detects that someone on the system\n" \
  1869. " console has pressed the CTRL-ALT-DEL key combination. Typically one\n" \
  1870. " wants to run 'reboot' at this point to cause the system to reboot.\n" \
  1871. " Finally the 'shutdown' action specifies the actions to taken when\n" \
  1872. " init is told to reboot. Unmounting filesystems and disabling swap\n" \
  1873. " is a very good here.\n" \
  1874. "\n" \
  1875. " Run repeatedly actions:\n" \
  1876. "\n" \
  1877. " 'respawn' actions are run after the 'once' actions. When a process\n" \
  1878. " started with a 'respawn' action exits, init automatically restarts\n" \
  1879. " it. Unlike sysvinit, BusyBox init does not stop processes from\n" \
  1880. " respawning out of control. The 'askfirst' actions acts just like\n" \
  1881. " respawn, except that before running the specified process it\n" \
  1882. " displays the line \"Please press Enter to activate this console.\"\n" \
  1883. " and then waits for the user to press enter before starting the\n" \
  1884. " specified process.\n" \
  1885. "\n" \
  1886. " Unrecognized actions (like initdefault) will cause init to emit an\n" \
  1887. " error message, and then go along with its business. All actions are\n" \
  1888. " run in the order they appear in /etc/inittab.\n" \
  1889. "\n" \
  1890. " <process>:\n" \
  1891. "\n" \
  1892. " Specifies the process to be executed and its command line.\n" \
  1893. "\n" \
  1894. "Example /etc/inittab file:\n" \
  1895. "\n" \
  1896. " # This is run first except when booting in single-user mode\n" \
  1897. " #\n" \
  1898. " ::sysinit:/etc/init.d/rcS\n" \
  1899. " \n" \
  1900. " # /bin/sh invocations on selected ttys\n" \
  1901. " #\n" \
  1902. " # Start an \"askfirst\" shell on the console (whatever that may be)\n" \
  1903. " ::askfirst:-/bin/sh\n" \
  1904. " # Start an \"askfirst\" shell on /dev/tty2-4\n" \
  1905. " tty2::askfirst:-/bin/sh\n" \
  1906. " tty3::askfirst:-/bin/sh\n" \
  1907. " tty4::askfirst:-/bin/sh\n" \
  1908. " \n" \
  1909. " # /sbin/getty invocations for selected ttys\n" \
  1910. " #\n" \
  1911. " tty4::respawn:/sbin/getty 38400 tty4\n" \
  1912. " tty5::respawn:/sbin/getty 38400 tty5\n" \
  1913. " \n" \
  1914. " \n" \
  1915. " # Example of how to put a getty on a serial line (for a terminal)\n" \
  1916. " #\n" \
  1917. " #::respawn:/sbin/getty -L ttyS0 9600 vt100\n" \
  1918. " #::respawn:/sbin/getty -L ttyS1 9600 vt100\n" \
  1919. " #\n" \
  1920. " # Example how to put a getty on a modem line\n" \
  1921. " #::respawn:/sbin/getty 57600 ttyS2\n" \
  1922. " \n" \
  1923. " # Stuff to do when restarting the init process\n" \
  1924. " ::restart:/sbin/init\n" \
  1925. " \n" \
  1926. " # Stuff to do before rebooting\n" \
  1927. " ::ctrlaltdel:/sbin/reboot\n" \
  1928. " ::shutdown:/bin/umount -a -r\n" \
  1929. " ::shutdown:/sbin/swapoff -a\n"
  1930. #define inotifyd_trivial_usage \
  1931. "PROG FILE1[:MASK]..."
  1932. #define inotifyd_full_usage "\n\n" \
  1933. "Run PROG on filesystem changes." \
  1934. "\nWhen a filesystem event matching MASK occurs on FILEn," \
  1935. "\nPROG ACTUAL_EVENTS FILEn [SUBFILE] is run." \
  1936. "\nEvents:" \
  1937. "\n a File is accessed" \
  1938. "\n c File is modified" \
  1939. "\n e Metadata changed" \
  1940. "\n w Writable file is closed" \
  1941. "\n 0 Unwritable file is closed" \
  1942. "\n r File is opened" \
  1943. "\n D File is deleted" \
  1944. "\n M File is moved" \
  1945. "\n u Backing fs is unmounted" \
  1946. "\n o Event queue overflowed" \
  1947. "\n x File can't be watched anymore" \
  1948. "\nIf watching a directory:" \
  1949. "\n m Subfile is moved into dir" \
  1950. "\n y Subfile is moved out of dir" \
  1951. "\n n Subfile is created" \
  1952. "\n d Subfile is deleted" \
  1953. "\n" \
  1954. "\ninotifyd waits for PROG to exit." \
  1955. "\nWhen x event happens for all FILEs, inotifyd exits." \
  1956. /* 2.6 style insmod has no options and required filename
  1957. * (not module name - .ko can't be omitted) */
  1958. #define insmod_trivial_usage \
  1959. IF_FEATURE_2_4_MODULES("[OPTIONS] MODULE ") \
  1960. IF_NOT_FEATURE_2_4_MODULES("FILE ") \
  1961. "[symbol=value]..."
  1962. #define insmod_full_usage "\n\n" \
  1963. "Load the specified kernel modules into the kernel" \
  1964. IF_FEATURE_2_4_MODULES( "\n" \
  1965. "\nOptions:" \
  1966. "\n -f Force module to load into the wrong kernel version" \
  1967. "\n -k Make module autoclean-able" \
  1968. "\n -v Verbose" \
  1969. "\n -q Quiet" \
  1970. "\n -L Lock to prevent simultaneous loads of a module" \
  1971. IF_FEATURE_INSMOD_LOAD_MAP( \
  1972. "\n -m Output load map to stdout" \
  1973. ) \
  1974. "\n -o NAME Set internal module name to NAME" \
  1975. "\n -x Don't export externs" \
  1976. )
  1977. /* -v, -b, -c are ignored */
  1978. #define install_trivial_usage \
  1979. "[-cdDsp] [-o USER] [-g GRP] [-m MODE] [SOURCE]... DEST"
  1980. #define install_full_usage "\n\n" \
  1981. "Copy files and set attributes\n" \
  1982. "\nOptions:" \
  1983. "\n -c Just copy (default)" \
  1984. "\n -d Create directories" \
  1985. "\n -D Create leading target directories" \
  1986. "\n -s Strip symbol table" \
  1987. "\n -p Preserve date" \
  1988. "\n -o USER Set ownership" \
  1989. "\n -g GRP Set group ownership" \
  1990. "\n -m MODE Set permissions" \
  1991. IF_SELINUX( \
  1992. "\n -Z Set security context" \
  1993. )
  1994. #define ionice_trivial_usage \
  1995. "[-c 1-3] [-n 0-7] [-p PID] [PROG]"
  1996. #define ionice_full_usage "\n\n" \
  1997. "Change I/O scheduling class and priority\n" \
  1998. "\nOptions:" \
  1999. "\n -c Class. 1:realtime 2:best-effort 3:idle" \
  2000. "\n -n Priority" \
  2001. /* would need to make the " | " optional depending on more than one selected: */
  2002. #define ip_trivial_usage \
  2003. "[OPTIONS] {" \
  2004. IF_FEATURE_IP_ADDRESS("address | ") \
  2005. IF_FEATURE_IP_ROUTE("route | ") \
  2006. IF_FEATURE_IP_LINK("link | ") \
  2007. IF_FEATURE_IP_TUNNEL("tunnel | ") \
  2008. IF_FEATURE_IP_RULE("rule") \
  2009. "} {COMMAND}"
  2010. #define ip_full_usage "\n\n" \
  2011. "ip [OPTIONS] OBJECT {COMMAND}\n" \
  2012. "where OBJECT := {" \
  2013. IF_FEATURE_IP_ADDRESS("address | ") \
  2014. IF_FEATURE_IP_ROUTE("route | ") \
  2015. IF_FEATURE_IP_LINK("link | ") \
  2016. IF_FEATURE_IP_TUNNEL("tunnel | ") \
  2017. IF_FEATURE_IP_RULE("rule") \
  2018. "}\n" \
  2019. "OPTIONS := { -f[amily] { inet | inet6 | link } | -o[neline] }" \
  2020. #define ipaddr_trivial_usage \
  2021. "{ {add|del} IFADDR dev STRING | {show|flush}\n" \
  2022. " [dev STRING] [to PREFIX] }"
  2023. #define ipaddr_full_usage "\n\n" \
  2024. "ipaddr {add|delete} IFADDR dev STRING\n" \
  2025. "ipaddr {show|flush} [dev STRING] [scope SCOPE-ID]\n" \
  2026. " [to PREFIX] [label PATTERN]\n" \
  2027. " IFADDR := PREFIX | ADDR peer PREFIX\n" \
  2028. " [broadcast ADDR] [anycast ADDR]\n" \
  2029. " [label STRING] [scope SCOPE-ID]\n" \
  2030. " SCOPE-ID := [host | link | global | NUMBER]" \
  2031. #define ipcalc_trivial_usage \
  2032. "[OPTIONS] ADDRESS[[/]NETMASK] [NETMASK]"
  2033. #define ipcalc_full_usage "\n\n" \
  2034. "Calculate IP network settings from a IP address\n" \
  2035. "\nOptions:" \
  2036. IF_FEATURE_IPCALC_LONG_OPTIONS( \
  2037. "\n -b,--broadcast Display calculated broadcast address" \
  2038. "\n -n,--network Display calculated network address" \
  2039. "\n -m,--netmask Display default netmask for IP" \
  2040. IF_FEATURE_IPCALC_FANCY( \
  2041. "\n -p,--prefix Display the prefix for IP/NETMASK" \
  2042. "\n -h,--hostname Display first resolved host name" \
  2043. "\n -s,--silent Don't ever display error messages" \
  2044. ) \
  2045. ) \
  2046. IF_NOT_FEATURE_IPCALC_LONG_OPTIONS( \
  2047. "\n -b Display calculated broadcast address" \
  2048. "\n -n Display calculated network address" \
  2049. "\n -m Display default netmask for IP" \
  2050. IF_FEATURE_IPCALC_FANCY( \
  2051. "\n -p Display the prefix for IP/NETMASK" \
  2052. "\n -h Display first resolved host name" \
  2053. "\n -s Don't ever display error messages" \
  2054. ) \
  2055. )
  2056. #define ipcrm_trivial_usage \
  2057. "[-MQS key] [-mqs id]"
  2058. #define ipcrm_full_usage "\n\n" \
  2059. "Upper-case options MQS remove an object by shmkey value.\n" \
  2060. "Lower-case options remove an object by shmid value.\n" \
  2061. "\nOptions:" \
  2062. "\n -mM Remove memory segment after last detach" \
  2063. "\n -qQ Remove message queue" \
  2064. "\n -sS Remove semaphore" \
  2065. #define ipcs_trivial_usage \
  2066. "[[-smq] -i shmid] | [[-asmq] [-tcplu]]"
  2067. #define ipcs_full_usage "\n\n" \
  2068. " -i Show specific resource" \
  2069. "\nResource specification:" \
  2070. "\n -m Shared memory segments" \
  2071. "\n -q Message queues" \
  2072. "\n -s Semaphore arrays" \
  2073. "\n -a All (default)" \
  2074. "\nOutput format:" \
  2075. "\n -t Time" \
  2076. "\n -c Creator" \
  2077. "\n -p Pid" \
  2078. "\n -l Limits" \
  2079. "\n -u Summary" \
  2080. #define iplink_trivial_usage \
  2081. "{ set DEVICE { up | down | arp { on | off } | show [DEVICE] }"
  2082. #define iplink_full_usage "\n\n" \
  2083. "iplink set DEVICE { up | down | arp | multicast { on | off } |\n" \
  2084. " dynamic { on | off } |\n" \
  2085. " mtu MTU }\n" \
  2086. "iplink show [DEVICE]" \
  2087. #define iproute_trivial_usage \
  2088. "{ list | flush | { add | del | change | append |\n" \
  2089. " replace | monitor } ROUTE }"
  2090. #define iproute_full_usage "\n\n" \
  2091. "iproute { list | flush } SELECTOR\n" \
  2092. "iproute get ADDRESS [from ADDRESS iif STRING]\n" \
  2093. " [oif STRING] [tos TOS]\n" \
  2094. "iproute { add | del | change | append | replace | monitor } ROUTE\n" \
  2095. " SELECTOR := [root PREFIX] [match PREFIX] [proto RTPROTO]\n" \
  2096. " ROUTE := [TYPE] PREFIX [tos TOS] [proto RTPROTO]\n" \
  2097. " [metric METRIC]" \
  2098. #define iprule_trivial_usage \
  2099. "{[list | add | del] RULE}"
  2100. #define iprule_full_usage "\n\n" \
  2101. "iprule [list | add | del] SELECTOR ACTION\n" \
  2102. " SELECTOR := [from PREFIX] [to PREFIX] [tos TOS] [fwmark FWMARK]\n" \
  2103. " [dev STRING] [pref NUMBER]\n" \
  2104. " ACTION := [table TABLE_ID] [nat ADDRESS]\n" \
  2105. " [prohibit | reject | unreachable]\n" \
  2106. " [realms [SRCREALM/]DSTREALM]\n" \
  2107. " TABLE_ID := [local | main | default | NUMBER]" \
  2108. #define iptunnel_trivial_usage \
  2109. "{ add | change | del | show } [NAME]\n" \
  2110. " [mode { ipip | gre | sit }]\n" \
  2111. " [remote ADDR] [local ADDR] [ttl TTL]"
  2112. #define iptunnel_full_usage "\n\n" \
  2113. "iptunnel { add | change | del | show } [NAME]\n" \
  2114. " [mode { ipip | gre | sit }] [remote ADDR] [local ADDR]\n" \
  2115. " [[i|o]seq] [[i|o]key KEY] [[i|o]csum]\n" \
  2116. " [ttl TTL] [tos TOS] [[no]pmtudisc] [dev PHYS_DEV]" \
  2117. #define kbd_mode_trivial_usage \
  2118. "[-a|k|s|u] [-C TTY]"
  2119. #define kbd_mode_full_usage "\n\n" \
  2120. "Report or set the keyboard mode\n" \
  2121. "\nOptions:" \
  2122. "\n -a Default (ASCII)" \
  2123. "\n -k Medium-raw (keyboard)" \
  2124. "\n -s Raw (scancode)" \
  2125. "\n -u Unicode (utf-8)" \
  2126. "\n -C TTY Affect TTY instead of /dev/tty" \
  2127. #define kill_trivial_usage \
  2128. "[-l] [-SIG] PID..."
  2129. #define kill_full_usage "\n\n" \
  2130. "Send a signal (default: TERM) to given PIDs\n" \
  2131. "\nOptions:" \
  2132. "\n -l List all signal names and numbers" \
  2133. /* "\n -s SIG Yet another way of specifying SIG" */ \
  2134. #define kill_example_usage \
  2135. "$ ps | grep apache\n" \
  2136. "252 root root S [apache]\n" \
  2137. "263 www-data www-data S [apache]\n" \
  2138. "264 www-data www-data S [apache]\n" \
  2139. "265 www-data www-data S [apache]\n" \
  2140. "266 www-data www-data S [apache]\n" \
  2141. "267 www-data www-data S [apache]\n" \
  2142. "$ kill 252\n"
  2143. #define killall_trivial_usage \
  2144. "[-l] [-q] [-SIG] PROCESS_NAME..."
  2145. #define killall_full_usage "\n\n" \
  2146. "Send a signal (default: TERM) to given processes\n" \
  2147. "\nOptions:" \
  2148. "\n -l List all signal names and numbers" \
  2149. /* "\n -s SIG Yet another way of specifying SIG" */ \
  2150. "\n -q Don't complain if no processes were killed" \
  2151. #define killall_example_usage \
  2152. "$ killall apache\n"
  2153. #define killall5_trivial_usage \
  2154. "[-l] [-SIG] [-o PID]..."
  2155. #define killall5_full_usage "\n\n" \
  2156. "Send a signal (default: TERM) to all processes outside current session\n" \
  2157. "\nOptions:" \
  2158. "\n -l List all signal names and numbers" \
  2159. "\n -o PID Don't signal this PID" \
  2160. /* "\n -s SIG Yet another way of specifying SIG" */ \
  2161. #define klogd_trivial_usage \
  2162. "[-c N] [-n]"
  2163. #define klogd_full_usage "\n\n" \
  2164. "Kernel logger\n" \
  2165. "\nOptions:" \
  2166. "\n -c N Only messages with level < N are printed to console" \
  2167. "\n -n Run in foreground" \
  2168. #define length_trivial_usage \
  2169. "STRING"
  2170. #define length_full_usage "\n\n" \
  2171. "Print STRING's length"
  2172. #define length_example_usage \
  2173. "$ length Hello\n" \
  2174. "5\n"
  2175. #define less_trivial_usage \
  2176. "[-EMNmh~I?] [FILE]..."
  2177. #define less_full_usage "\n\n" \
  2178. "View FILE (or stdin) one screenful at a time\n" \
  2179. "\nOptions:" \
  2180. "\n -E Quit once the end of a file is reached" \
  2181. "\n -M,-m Display status line with line numbers" \
  2182. "\n and percentage through the file" \
  2183. "\n -N Prefix line number to each line" \
  2184. "\n -I Ignore case in all searches" \
  2185. "\n -~ Suppress ~s displayed past the end of the file" \
  2186. #define linux32_trivial_usage NOUSAGE_STR
  2187. #define linux32_full_usage ""
  2188. #define linux64_trivial_usage NOUSAGE_STR
  2189. #define linux64_full_usage ""
  2190. #define linuxrc_trivial_usage NOUSAGE_STR
  2191. #define linuxrc_full_usage ""
  2192. #define setarch_trivial_usage \
  2193. "personality PROG ARGS"
  2194. #define setarch_full_usage "\n\n" \
  2195. "Personality may be:\n" \
  2196. " linux32 Set 32bit uname emulation\n" \
  2197. " linux64 Set 64bit uname emulation" \
  2198. #define ln_trivial_usage \
  2199. "[OPTIONS] TARGET... LINK|DIR"
  2200. #define ln_full_usage "\n\n" \
  2201. "Create a link LINK or DIR/TARGET to the specified TARGET(s)\n" \
  2202. "\nOptions:" \
  2203. "\n -s Make symlinks instead of hardlinks" \
  2204. "\n -f Remove existing destinations" \
  2205. "\n -n Don't dereference symlinks - treat like normal file" \
  2206. "\n -b Make a backup of the target (if exists) before link operation" \
  2207. "\n -S suf Use suffix instead of ~ when making backup files" \
  2208. #define ln_example_usage \
  2209. "$ ln -s BusyBox /tmp/ls\n" \
  2210. "$ ls -l /tmp/ls\n" \
  2211. "lrwxrwxrwx 1 root root 7 Apr 12 18:39 ls -> BusyBox*\n"
  2212. #define load_policy_trivial_usage NOUSAGE_STR
  2213. #define load_policy_full_usage ""
  2214. #define loadfont_trivial_usage \
  2215. "< font"
  2216. #define loadfont_full_usage "\n\n" \
  2217. "Load a console font from stdin" \
  2218. /* "\n -C TTY Affect TTY instead of /dev/tty" */ \
  2219. #define loadfont_example_usage \
  2220. "$ loadfont < /etc/i18n/fontname\n"
  2221. #define loadkmap_trivial_usage \
  2222. "< keymap"
  2223. #define loadkmap_full_usage "\n\n" \
  2224. "Load a binary keyboard translation table from stdin\n" \
  2225. /* "\n -C TTY Affect TTY instead of /dev/tty" */ \
  2226. #define loadkmap_example_usage \
  2227. "$ loadkmap < /etc/i18n/lang-keymap\n"
  2228. #define logger_trivial_usage \
  2229. "[OPTIONS] [MESSAGE]"
  2230. #define logger_full_usage "\n\n" \
  2231. "Write MESSAGE (or stdin) to syslog\n" \
  2232. "\nOptions:" \
  2233. "\n -s Log to stderr as well as the system log" \
  2234. "\n -t TAG Log using the specified tag (defaults to user name)" \
  2235. "\n -p PRIO Priority (numeric or facility.level pair)" \
  2236. #define logger_example_usage \
  2237. "$ logger \"hello\"\n"
  2238. #define login_trivial_usage \
  2239. "[-p] [-h HOST] [[-f] USER]"
  2240. #define login_full_usage "\n\n" \
  2241. "Begin a new session on the system\n" \
  2242. "\nOptions:" \
  2243. "\n -f Don't authenticate (user already authenticated)" \
  2244. "\n -h Name of the remote host" \
  2245. "\n -p Preserve environment" \
  2246. #define logname_trivial_usage \
  2247. ""
  2248. #define logname_full_usage "\n\n" \
  2249. "Print the name of the current user"
  2250. #define logname_example_usage \
  2251. "$ logname\n" \
  2252. "root\n"
  2253. #define logread_trivial_usage \
  2254. "[OPTIONS]"
  2255. #define logread_full_usage "\n\n" \
  2256. "Show messages in syslogd's circular buffer\n" \
  2257. "\nOptions:" \
  2258. "\n -f Output data as log grows" \
  2259. #define losetup_trivial_usage \
  2260. "[-o OFS] LOOPDEV FILE - associate loop devices\n" \
  2261. " losetup -d LOOPDEV - disassociate\n" \
  2262. " losetup [-f] - show"
  2263. #define losetup_full_usage "\n\n" \
  2264. "Options:" \
  2265. "\n -o OFS Start OFS bytes into FILE" \
  2266. "\n -f Show first free loop device" \
  2267. #define losetup_notes_usage \
  2268. "No arguments will display all current associations.\n" \
  2269. "One argument (losetup /dev/loop1) will display the current association\n" \
  2270. "(if any), or disassociate it (with -d). The display shows the offset\n" \
  2271. "and filename of the file the loop device is currently bound to.\n\n" \
  2272. "Two arguments (losetup /dev/loop1 file.img) create a new association,\n" \
  2273. "with an optional offset (-o 12345). Encryption is not yet supported.\n" \
  2274. "losetup -f will show the first loop free loop device\n\n"
  2275. #define lpd_trivial_usage \
  2276. "SPOOLDIR [HELPER [ARGS]]"
  2277. #define lpd_full_usage "\n\n" \
  2278. "SPOOLDIR must contain (symlinks to) device nodes or directories" \
  2279. "\nwith names matching print queue names. In the first case, jobs are" \
  2280. "\nsent directly to the device. Otherwise each job is stored in queue" \
  2281. "\ndirectory and HELPER program is called. Name of file to print" \
  2282. "\nis passed in $DATAFILE variable." \
  2283. "\nExample:" \
  2284. "\n tcpsvd -E 0 515 softlimit -m 999999 lpd /var/spool ./print" \
  2285. #define lpq_trivial_usage \
  2286. "[-P queue[@host[:port]]] [-U USERNAME] [-d JOBID]... [-fs]"
  2287. #define lpq_full_usage "\n\n" \
  2288. "Options:" \
  2289. "\n -P lp service to connect to (else uses $PRINTER)" \
  2290. "\n -d Delete jobs" \
  2291. "\n -f Force any waiting job to be printed" \
  2292. "\n -s Short display" \
  2293. #define lpr_trivial_usage \
  2294. "-P queue[@host[:port]] -U USERNAME -J TITLE -Vmh [FILE]..."
  2295. /* -C CLASS exists too, not shown.
  2296. * CLASS is supposed to be printed on banner page, if one is requested */
  2297. #define lpr_full_usage "\n\n" \
  2298. "Options:" \
  2299. "\n -P lp service to connect to (else uses $PRINTER)"\
  2300. "\n -m Send mail on completion" \
  2301. "\n -h Print banner page too" \
  2302. "\n -V Verbose" \
  2303. #define ls_trivial_usage \
  2304. "[-1Aa" IF_FEATURE_LS_TIMESTAMPS("c") "Cd" \
  2305. IF_FEATURE_LS_TIMESTAMPS("e") IF_FEATURE_LS_FILETYPES("F") "iln" \
  2306. IF_FEATURE_LS_FILETYPES("p") IF_FEATURE_LS_FOLLOWLINKS("L") \
  2307. IF_FEATURE_LS_RECURSIVE("R") IF_FEATURE_LS_SORTFILES("rS") "s" \
  2308. IF_FEATURE_AUTOWIDTH("T") IF_FEATURE_LS_TIMESTAMPS("tu") \
  2309. IF_FEATURE_LS_SORTFILES("v") IF_FEATURE_AUTOWIDTH("w") "x" \
  2310. IF_FEATURE_LS_SORTFILES("X") IF_FEATURE_HUMAN_READABLE("h") "k" \
  2311. IF_SELINUX("K") "] [FILE]..."
  2312. #define ls_full_usage "\n\n" \
  2313. "List directory contents\n" \
  2314. "\nOptions:" \
  2315. "\n -1 List in a single column" \
  2316. "\n -A Don't list . and .." \
  2317. "\n -a Don't hide entries starting with ." \
  2318. "\n -C List by columns" \
  2319. IF_FEATURE_LS_TIMESTAMPS( \
  2320. "\n -c With -l: sort by ctime") \
  2321. IF_FEATURE_LS_COLOR( \
  2322. "\n --color[={always,never,auto}] Control coloring") \
  2323. "\n -d List directory entries instead of contents" \
  2324. IF_FEATURE_LS_TIMESTAMPS( \
  2325. "\n -e List full date and time") \
  2326. IF_FEATURE_LS_FILETYPES( \
  2327. "\n -F Append indicator (one of */=@|) to entries") \
  2328. "\n -i List inode numbers" \
  2329. "\n -l Long listing format" \
  2330. "\n -n List numeric UIDs and GIDs instead of names" \
  2331. IF_FEATURE_LS_FILETYPES( \
  2332. "\n -p Append indicator (one of /=@|) to entries") \
  2333. IF_FEATURE_LS_FOLLOWLINKS( \
  2334. "\n -L List entries pointed to by symlinks") \
  2335. IF_FEATURE_LS_RECURSIVE( \
  2336. "\n -R Recurse") \
  2337. IF_FEATURE_LS_SORTFILES( \
  2338. "\n -r Sort in reverse order") \
  2339. IF_FEATURE_LS_SORTFILES( \
  2340. "\n -S Sort by file size") \
  2341. "\n -s List the size of each file, in blocks" \
  2342. IF_FEATURE_AUTOWIDTH( \
  2343. "\n -T N Assume tabstop every N columns") \
  2344. IF_FEATURE_LS_TIMESTAMPS( \
  2345. "\n -t With -l: sort by modification time") \
  2346. IF_FEATURE_LS_TIMESTAMPS( \
  2347. "\n -u With -l: sort by access time") \
  2348. IF_FEATURE_LS_SORTFILES( \
  2349. "\n -v Sort by version") \
  2350. IF_FEATURE_AUTOWIDTH( \
  2351. "\n -w N Assume the terminal is N columns wide") \
  2352. "\n -x List by lines" \
  2353. IF_FEATURE_LS_SORTFILES( \
  2354. "\n -X Sort by extension") \
  2355. IF_FEATURE_HUMAN_READABLE( \
  2356. "\n -h List sizes in human readable format (1K 243M 2G)") \
  2357. IF_SELINUX( \
  2358. "\n -k List security context") \
  2359. IF_SELINUX( \
  2360. "\n -K List security context in long format") \
  2361. IF_SELINUX( \
  2362. "\n -Z List security context and permission") \
  2363. #define lsattr_trivial_usage \
  2364. "[-Radlv] [FILE]..."
  2365. #define lsattr_full_usage "\n\n" \
  2366. "List file attributes on an ext2 fs\n" \
  2367. "\nOptions:" \
  2368. "\n -R Recurse" \
  2369. "\n -a Don't hide entries starting with ." \
  2370. "\n -d List directory entries instead of contents" \
  2371. "\n -l List long flag names" \
  2372. "\n -v List the file's version/generation number" \
  2373. #define lsmod_trivial_usage \
  2374. ""
  2375. #define lsmod_full_usage "\n\n" \
  2376. "List the currently loaded kernel modules"
  2377. #define lspci_trivial_usage \
  2378. "[-mk]"
  2379. #define lspci_full_usage "\n\n" \
  2380. "List all PCI devices" \
  2381. "\n" \
  2382. "\n -m Parseable output" \
  2383. "\n -k Show driver" \
  2384. #define lsusb_trivial_usage NOUSAGE_STR
  2385. #define lsusb_full_usage ""
  2386. #if ENABLE_FEATURE_MAKEDEVS_LEAF
  2387. #define makedevs_trivial_usage \
  2388. "NAME TYPE MAJOR MINOR FIRST LAST [s]"
  2389. #define makedevs_full_usage "\n\n" \
  2390. "Create a range of block or character special files" \
  2391. "\n" \
  2392. "\nTYPE is:" \
  2393. "\n b Block device" \
  2394. "\n c Character device" \
  2395. "\n f FIFO, MAJOR and MINOR are ignored" \
  2396. "\n" \
  2397. "\nFIRST..LAST specify numbers appended to NAME." \
  2398. "\nIf 's' is the last argument, the base device is created as well." \
  2399. "\n" \
  2400. "\nExamples:" \
  2401. "\n makedevs /dev/ttyS c 4 66 2 63 -> ttyS2-ttyS63" \
  2402. "\n makedevs /dev/hda b 3 0 0 8 s -> hda,hda1-hda8"
  2403. #define makedevs_example_usage \
  2404. "# makedevs /dev/ttyS c 4 66 2 63\n" \
  2405. "[creates ttyS2-ttyS63]\n" \
  2406. "# makedevs /dev/hda b 3 0 0 8 s\n" \
  2407. "[creates hda,hda1-hda8]\n"
  2408. #endif
  2409. #if ENABLE_FEATURE_MAKEDEVS_TABLE
  2410. #define makedevs_trivial_usage \
  2411. "[-d device_table] rootdir"
  2412. #define makedevs_full_usage "\n\n" \
  2413. "Create a range of special files as specified in a device table.\n" \
  2414. "Device table entries take the form of:\n" \
  2415. "<type> <mode> <uid> <gid> <major> <minor> <start> <inc> <count>\n" \
  2416. "Where name is the file name, type can be one of:\n" \
  2417. " f Regular file\n" \
  2418. " d Directory\n" \
  2419. " c Character device\n" \
  2420. " b Block device\n" \
  2421. " p Fifo (named pipe)\n" \
  2422. "uid is the user id for the target file, gid is the group id for the\n" \
  2423. "target file. The rest of the entries (major, minor, etc) apply to\n" \
  2424. "to device special files. A '-' may be used for blank entries."
  2425. #define makedevs_example_usage \
  2426. "For example:\n" \
  2427. "<name> <type> <mode><uid><gid><major><minor><start><inc><count>\n" \
  2428. "/dev d 755 0 0 - - - - -\n" \
  2429. "/dev/console c 666 0 0 5 1 - - -\n" \
  2430. "/dev/null c 666 0 0 1 3 0 0 -\n" \
  2431. "/dev/zero c 666 0 0 1 5 0 0 -\n" \
  2432. "/dev/hda b 640 0 0 3 0 0 0 -\n" \
  2433. "/dev/hda b 640 0 0 3 1 1 1 15\n\n" \
  2434. "Will Produce:\n" \
  2435. "/dev\n" \
  2436. "/dev/console\n" \
  2437. "/dev/null\n" \
  2438. "/dev/zero\n" \
  2439. "/dev/hda\n" \
  2440. "/dev/hda[0-15]\n"
  2441. #endif
  2442. #define makemime_trivial_usage \
  2443. "[OPTIONS] [FILE]..."
  2444. #define makemime_full_usage "\n\n" \
  2445. "Create multipart MIME-encoded message from FILEs\n" \
  2446. /* "Transfer encoding is base64, disposition is inline (not attachment)\n" */ \
  2447. "\nOptions:" \
  2448. "\n -o FILE Output. Default: stdout" \
  2449. "\n -a HDR Add header. Examples:" \
  2450. "\n \"From: user@host.org\", \"Date: `date -R`\"" \
  2451. "\n -c CT Content type. Default: text/plain" \
  2452. "\n -C CS Charset. Default: " CONFIG_FEATURE_MIME_CHARSET \
  2453. /* "\n -e ENC Transfer encoding. Ignored. base64 is assumed" */ \
  2454. "\n" \
  2455. "\nOther options are silently ignored" \
  2456. #define man_trivial_usage \
  2457. "[OPTIONS] [MANPAGE]..."
  2458. #define man_full_usage "\n\n" \
  2459. "Format and display manual page\n" \
  2460. "\nOptions:" \
  2461. "\n -a Display all pages" \
  2462. "\n -w Show page locations" \
  2463. #define matchpathcon_trivial_usage \
  2464. "[-n] [-N] [-f file_contexts_file] [-p prefix] [-V]"
  2465. #define matchpathcon_full_usage "\n\n" \
  2466. " -n Don't display path" \
  2467. "\n -N Don't use translations" \
  2468. "\n -f Use alternate file_context file" \
  2469. "\n -p Use prefix to speed translations" \
  2470. "\n -V Verify file context on disk matches defaults" \
  2471. #define md5sum_trivial_usage \
  2472. "[OPTIONS] [FILE]..." \
  2473. IF_FEATURE_MD5_SHA1_SUM_CHECK("\n or: md5sum [OPTIONS] -c [FILE]")
  2474. #define md5sum_full_usage "\n\n" \
  2475. "Print" IF_FEATURE_MD5_SHA1_SUM_CHECK(" or check") " MD5 checksums" \
  2476. IF_FEATURE_MD5_SHA1_SUM_CHECK( "\n" \
  2477. "\nOptions:" \
  2478. "\n -c Check sums against given list" \
  2479. "\n -s Don't output anything, status code shows success" \
  2480. "\n -w Warn about improperly formatted checksum lines" \
  2481. )
  2482. #define md5sum_example_usage \
  2483. "$ md5sum < busybox\n" \
  2484. "6fd11e98b98a58f64ff3398d7b324003\n" \
  2485. "$ md5sum busybox\n" \
  2486. "6fd11e98b98a58f64ff3398d7b324003 busybox\n" \
  2487. "$ md5sum -c -\n" \
  2488. "6fd11e98b98a58f64ff3398d7b324003 busybox\n" \
  2489. "busybox: OK\n" \
  2490. "^D\n"
  2491. #define sha1sum_trivial_usage \
  2492. "[OPTIONS] [FILE]..." \
  2493. IF_FEATURE_MD5_SHA1_SUM_CHECK("\n or: sha1sum [OPTIONS] -c [FILE]")
  2494. #define sha1sum_full_usage "\n\n" \
  2495. "Print" IF_FEATURE_MD5_SHA1_SUM_CHECK(" or check") " SHA1 checksums" \
  2496. IF_FEATURE_MD5_SHA1_SUM_CHECK( "\n" \
  2497. "\nOptions:" \
  2498. "\n -c Check sums against given list" \
  2499. "\n -s Don't output anything, status code shows success" \
  2500. "\n -w Warn about improperly formatted checksum lines" \
  2501. )
  2502. #define sha256sum_trivial_usage \
  2503. "[OPTIONS] [FILE]..." \
  2504. IF_FEATURE_MD5_SHA1_SUM_CHECK("\n or: sha256sum [OPTIONS] -c [FILE]")
  2505. #define sha256sum_full_usage "\n\n" \
  2506. "Print" IF_FEATURE_MD5_SHA1_SUM_CHECK(" or check") " SHA256 checksums" \
  2507. IF_FEATURE_MD5_SHA1_SUM_CHECK( "\n" \
  2508. "\nOptions:" \
  2509. "\n -c Check sums against given list" \
  2510. "\n -s Don't output anything, status code shows success" \
  2511. "\n -w Warn about improperly formatted checksum lines" \
  2512. )
  2513. #define sha512sum_trivial_usage \
  2514. "[OPTIONS] [FILE]..." \
  2515. IF_FEATURE_MD5_SHA1_SUM_CHECK("\n or: sha512sum [OPTIONS] -c [FILE]")
  2516. #define sha512sum_full_usage "\n\n" \
  2517. "Print" IF_FEATURE_MD5_SHA1_SUM_CHECK(" or check") " SHA512 checksums" \
  2518. IF_FEATURE_MD5_SHA1_SUM_CHECK( "\n" \
  2519. "\nOptions:" \
  2520. "\n -c Check sums against given list" \
  2521. "\n -s Don't output anything, status code shows success" \
  2522. "\n -w Warn about improperly formatted checksum lines" \
  2523. )
  2524. #define mdev_trivial_usage \
  2525. "[-s]"
  2526. #define mdev_full_usage "\n\n" \
  2527. " -s Scan /sys and populate /dev during system boot\n" \
  2528. "\n" \
  2529. "It can be run by kernel as a hotplug helper. To activate it:\n" \
  2530. " echo /sbin/mdev > /proc/sys/kernel/hotplug\n" \
  2531. IF_FEATURE_MDEV_CONF( \
  2532. "It uses /etc/mdev.conf with lines\n" \
  2533. "[-]DEVNAME UID:GID PERM" \
  2534. IF_FEATURE_MDEV_RENAME(" [>|=PATH]") \
  2535. IF_FEATURE_MDEV_EXEC(" [@|$|*PROG]") \
  2536. ) \
  2537. #define mdev_notes_usage "" \
  2538. IF_FEATURE_MDEV_CONFIG( \
  2539. "The mdev config file contains lines that look like:\n" \
  2540. " hd[a-z][0-9]* 0:3 660\n\n" \
  2541. "That's device name (with regex match), uid:gid, and permissions.\n\n" \
  2542. IF_FEATURE_MDEV_EXEC( \
  2543. "Optionally, that can be followed (on the same line) by a special character\n" \
  2544. "and a command line to run after creating/before deleting the corresponding\n" \
  2545. "device(s). The environment variable $MDEV indicates the active device node\n" \
  2546. "(which is useful if it's a regex match). For example:\n\n" \
  2547. " hdc root:cdrom 660 *ln -s $MDEV cdrom\n\n" \
  2548. "The special characters are @ (run after creating), $ (run before deleting),\n" \
  2549. "and * (run both after creating and before deleting). The commands run in\n" \
  2550. "the /dev directory, and use system() which calls /bin/sh.\n\n" \
  2551. ) \
  2552. "Config file parsing stops on the first matching line. If no config\n" \
  2553. "entry is matched, devices are created with default 0:0 660. (Make\n" \
  2554. "the last line match .* to override this.)\n\n" \
  2555. )
  2556. #define mesg_trivial_usage \
  2557. "[y|n]"
  2558. #define mesg_full_usage "\n\n" \
  2559. "Control write access to your terminal\n" \
  2560. " y Allow write access to your terminal\n" \
  2561. " n Disallow write access to your terminal"
  2562. #define microcom_trivial_usage \
  2563. "[-d DELAY] [-t TIMEOUT] [-s SPEED] [-X] TTY"
  2564. #define microcom_full_usage "\n\n" \
  2565. "Copy bytes for stdin to TTY and from TTY to stdout\n" \
  2566. "\nOptions:" \
  2567. "\n -d Wait up to DELAY ms for TTY output before sending every" \
  2568. "\n next byte to it" \
  2569. "\n -t Exit if both stdin and TTY are silent for TIMEOUT ms" \
  2570. "\n -s Set serial line to SPEED" \
  2571. "\n -X Disable special meaning of NUL and Ctrl-X from stdin" \
  2572. #define mkdir_trivial_usage \
  2573. "[OPTIONS] DIRECTORY..."
  2574. #define mkdir_full_usage "\n\n" \
  2575. "Create DIRECTORY\n" \
  2576. "\nOptions:" \
  2577. "\n -m Mode" \
  2578. "\n -p No error if exists; make parent directories as needed" \
  2579. IF_SELINUX( \
  2580. "\n -Z Set security context" \
  2581. )
  2582. #define mkdir_example_usage \
  2583. "$ mkdir /tmp/foo\n" \
  2584. "$ mkdir /tmp/foo\n" \
  2585. "/tmp/foo: File exists\n" \
  2586. "$ mkdir /tmp/foo/bar/baz\n" \
  2587. "/tmp/foo/bar/baz: No such file or directory\n" \
  2588. "$ mkdir -p /tmp/foo/bar/baz\n"
  2589. #define mkfifo_trivial_usage \
  2590. "[OPTIONS] name"
  2591. #define mkfifo_full_usage "\n\n" \
  2592. "Create named pipe (identical to 'mknod name p')\n" \
  2593. "\nOptions:" \
  2594. "\n -m MODE Mode (default a=rw)" \
  2595. IF_SELINUX( \
  2596. "\n -Z Set security context" \
  2597. )
  2598. #define mkfs_ext2_trivial_usage \
  2599. "[-Fn] " \
  2600. /* "[-c|-l filename] " */ \
  2601. "[-b BLK_SIZE] " \
  2602. /* "[-f fragment-size] [-g blocks-per-group] " */ \
  2603. "[-i INODE_RATIO] [-I INODE_SIZE] " \
  2604. /* "[-j] [-J journal-options] [-N number-of-inodes] " */ \
  2605. "[-m RESERVED_PERCENT] " \
  2606. /* "[-o creator-os] [-O feature[,...]] [-q] " */ \
  2607. /* "[r fs-revision-level] [-E extended-options] [-v] [-F] " */ \
  2608. "[-L LABEL] " \
  2609. /* "[-M last-mounted-directory] [-S] [-T filesystem-type] " */ \
  2610. "BLOCKDEV [KBYTES]"
  2611. #define mkfs_ext2_full_usage "\n\n" \
  2612. " -b BLK_SIZE Block size, bytes" \
  2613. /* "\n -c Check device for bad blocks" */ \
  2614. /* "\n -E opts Set extended options" */ \
  2615. /* "\n -f size Fragment size in bytes" */ \
  2616. "\n -F Force" \
  2617. /* "\n -g N Number of blocks in a block group" */ \
  2618. "\n -i RATIO Max number of files is filesystem_size / RATIO" \
  2619. "\n -I BYTES Inode size (min 128)" \
  2620. /* "\n -j Create a journal (ext3)" */ \
  2621. /* "\n -J opts Set journal options (size/device)" */ \
  2622. /* "\n -l file Read bad blocks list from file" */ \
  2623. "\n -L LBL Volume label" \
  2624. "\n -m PERCENT Percent of blocks to reserve for admin" \
  2625. /* "\n -M dir Set last mounted directory" */ \
  2626. "\n -n Dry run" \
  2627. /* "\n -N N Number of inodes to create" */ \
  2628. /* "\n -o os Set the 'creator os' field" */ \
  2629. /* "\n -O features Dir_index/filetype/has_journal/journal_dev/sparse_super" */ \
  2630. /* "\n -q Quiet" */ \
  2631. /* "\n -r rev Set filesystem revision" */ \
  2632. /* "\n -S Write superblock and group descriptors only" */ \
  2633. /* "\n -T fs-type Set usage type (news/largefile/largefile4)" */ \
  2634. /* "\n -v Verbose" */ \
  2635. #define mkfs_minix_trivial_usage \
  2636. "[-c | -l FILE] [-nXX] [-iXX] BLOCKDEV [KBYTES]"
  2637. #define mkfs_minix_full_usage "\n\n" \
  2638. "Make a MINIX filesystem\n" \
  2639. "\nOptions:" \
  2640. "\n -c Check device for bad blocks" \
  2641. "\n -n [14|30] Maximum length of filenames" \
  2642. "\n -i INODES Number of inodes for the filesystem" \
  2643. "\n -l FILE Read bad blocks list from FILE" \
  2644. "\n -v Make version 2 filesystem" \
  2645. #define mkfs_reiser_trivial_usage \
  2646. "[-f] [-l LABEL] BLOCKDEV [4K-BLOCKS]"
  2647. #define mkfs_reiser_full_usage "\n\n" \
  2648. "Make a ReiserFS V3 filesystem\n" \
  2649. "\nOptions:" \
  2650. "\n -f Force" \
  2651. "\n -l LBL Volume label" \
  2652. #define mkfs_vfat_trivial_usage \
  2653. "[-v] [-n LABEL] BLOCKDEV [KBYTES]"
  2654. /* Accepted but ignored:
  2655. "[-c] [-C] [-I] [-l bad-block-file] [-b backup-boot-sector] "
  2656. "[-m boot-msg-file] [-i volume-id] "
  2657. "[-s sectors-per-cluster] [-S logical-sector-size] [-f number-of-FATs] "
  2658. "[-h hidden-sectors] [-F fat-size] [-r root-dir-entries] [-R reserved-sectors] "
  2659. */
  2660. #define mkfs_vfat_full_usage "\n\n" \
  2661. "Make a FAT32 filesystem\n" \
  2662. "\nOptions:" \
  2663. /* "\n -c Check device for bad blocks" */ \
  2664. "\n -v Verbose" \
  2665. /* "\n -I Allow to use entire disk device (e.g. /dev/hda)" */ \
  2666. "\n -n LBL Volume label" \
  2667. #define mknod_trivial_usage \
  2668. "[OPTIONS] NAME TYPE MAJOR MINOR"
  2669. #define mknod_full_usage "\n\n" \
  2670. "Create a special file (block, character, or pipe)\n" \
  2671. "\nOptions:" \
  2672. "\n -m Create the special file using the specified mode (default a=rw)" \
  2673. "\nTYPEs include:" \
  2674. "\n b: Make a block device" \
  2675. "\n c or u: Make a character device" \
  2676. "\n p: Make a named pipe (MAJOR and MINOR are ignored)" \
  2677. IF_SELINUX( \
  2678. "\n -Z Set security context" \
  2679. )
  2680. #define mknod_example_usage \
  2681. "$ mknod /dev/fd0 b 2 0\n" \
  2682. "$ mknod -m 644 /tmp/pipe p\n"
  2683. #define mkswap_trivial_usage \
  2684. "[OPTIONS] BLOCKDEV [KBYTES]"
  2685. #define mkswap_full_usage "\n\n" \
  2686. "Prepare BLOCKDEV to be used as swap partition\n" \
  2687. "\nOptions:" \
  2688. "\n -L LBL Label" \
  2689. #define mktemp_trivial_usage \
  2690. "[-dt] [-p DIR] [TEMPLATE]"
  2691. #define mktemp_full_usage "\n\n" \
  2692. "Create a temporary file with name based on TEMPLATE and print its name.\n" \
  2693. "TEMPLATE must end with XXXXXX (e.g. [/dir/]nameXXXXXX).\n" \
  2694. "\nOptions:" \
  2695. "\n -d Make a directory instead of a file" \
  2696. /* "\n -q Fail silently if an error occurs" - we ignore it */ \
  2697. "\n -t Generate a path rooted in temporary directory" \
  2698. "\n -p DIR Use DIR as a temporary directory (implies -t)" \
  2699. "\n" \
  2700. "\nFor -t or -p, directory is chosen as follows:" \
  2701. "\n$TMPDIR if set, else -p DIR, else /tmp" \
  2702. #define mktemp_example_usage \
  2703. "$ mktemp /tmp/temp.XXXXXX\n" \
  2704. "/tmp/temp.mWiLjM\n" \
  2705. "$ ls -la /tmp/temp.mWiLjM\n" \
  2706. "-rw------- 1 andersen andersen 0 Apr 25 17:10 /tmp/temp.mWiLjM\n"
  2707. #define modprobe_trivial_usage \
  2708. IF_MODPROBE_SMALL("[-qfwrsv] MODULE [symbol=value]...") \
  2709. IF_NOT_MODPROBE_SMALL("[-" \
  2710. IF_FEATURE_2_4_MODULES("k")"nqrsv" \
  2711. IF_FEATURE_MODPROBE_BLACKLIST("b")"] MODULE [symbol=value]...")
  2712. #define modprobe_full_usage "\n\n" \
  2713. "Options:" \
  2714. IF_MODPROBE_SMALL( \
  2715. "\n -q Quiet" \
  2716. "\n -f Force" \
  2717. "\n -w Wait for unload" \
  2718. "\n -r Remove module (stacks) or do autoclean" \
  2719. "\n -s Report via syslog instead of stderr" \
  2720. "\n -v Verbose" \
  2721. ) \
  2722. IF_NOT_MODPROBE_SMALL( \
  2723. IF_FEATURE_2_4_MODULES( \
  2724. "\n -k Make module autoclean-able" \
  2725. ) \
  2726. "\n -n Dry run" \
  2727. "\n -q Quiet" \
  2728. "\n -r Remove module (stacks) or do autoclean" \
  2729. "\n -s Report via syslog instead of stderr" \
  2730. "\n -v Verbose" \
  2731. IF_FEATURE_MODPROBE_BLACKLIST( \
  2732. "\n -b Apply blacklist to module names too" \
  2733. ) \
  2734. )
  2735. #define modprobe_notes_usage \
  2736. "modprobe can (un)load a stack of modules, passing each module options (when\n" \
  2737. "loading). modprobe uses a configuration file to determine what option(s) to\n" \
  2738. "pass each module it loads.\n" \
  2739. "\n" \
  2740. "The configuration file is searched (in this order):\n" \
  2741. "\n" \
  2742. " /etc/modprobe.conf (2.6 only)\n" \
  2743. " /etc/modules.conf\n" \
  2744. " /etc/conf.modules (deprecated)\n" \
  2745. "\n" \
  2746. "They all have the same syntax (see below). If none is present, it is\n" \
  2747. "_not_ an error; each loaded module is then expected to load without\n" \
  2748. "options. Once a file is found, the others are tested for.\n" \
  2749. "\n" \
  2750. "/etc/modules.conf entry format:\n" \
  2751. "\n" \
  2752. " alias <alias_name> <mod_name>\n" \
  2753. " Makes it possible to modprobe alias_name, when there is no such module.\n" \
  2754. " It makes sense if your mod_name is long, or you want a more representative\n" \
  2755. " name for that module (eg. 'scsi' in place of 'aha7xxx').\n" \
  2756. " This makes it also possible to use a different set of options (below) for\n" \
  2757. " the module and the alias.\n" \
  2758. " A module can be aliased more than once.\n" \
  2759. "\n" \
  2760. " options <mod_name|alias_name> <symbol=value...>\n" \
  2761. " When loading module mod_name (or the module aliased by alias_name), pass\n" \
  2762. " the \"symbol=value\" pairs as option to that module.\n" \
  2763. "\n" \
  2764. "Sample /etc/modules.conf file:\n" \
  2765. "\n" \
  2766. " options tulip irq=3\n" \
  2767. " alias tulip tulip2\n" \
  2768. " options tulip2 irq=4 io=0x308\n" \
  2769. "\n" \
  2770. "Other functionality offered by 'classic' modprobe is not available in\n" \
  2771. "this implementation.\n" \
  2772. "\n" \
  2773. "If module options are present both in the config file, and on the command line,\n" \
  2774. "then the options from the command line will be passed to the module _after_\n" \
  2775. "the options from the config file. That way, you can have defaults in the config\n" \
  2776. "file, and override them for a specific usage from the command line.\n"
  2777. #define modprobe_example_usage \
  2778. "(with the above /etc/modules.conf):\n\n" \
  2779. "$ modprobe tulip\n" \
  2780. " will load the module 'tulip' with default option 'irq=3'\n\n" \
  2781. "$ modprobe tulip irq=5\n" \
  2782. " will load the module 'tulip' with option 'irq=5', thus overriding the default\n\n" \
  2783. "$ modprobe tulip2\n" \
  2784. " will load the module 'tulip' with default options 'irq=4 io=0x308',\n" \
  2785. " which are the default for alias 'tulip2'\n\n" \
  2786. "$ modprobe tulip2 irq=8\n" \
  2787. " will load the module 'tulip' with default options 'irq=4 io=0x308 irq=8',\n" \
  2788. " which are the default for alias 'tulip2' overridden by the option 'irq=8'\n\n" \
  2789. " from the command line\n\n" \
  2790. "$ modprobe tulip2 irq=2 io=0x210\n" \
  2791. " will load the module 'tulip' with default options 'irq=4 io=0x308 irq=4 io=0x210',\n" \
  2792. " which are the default for alias 'tulip2' overridden by the options 'irq=2 io=0x210'\n\n" \
  2793. " from the command line\n"
  2794. #define more_trivial_usage \
  2795. "[FILE]..."
  2796. #define more_full_usage "\n\n" \
  2797. "View FILE (or stdin) one screenful at a time"
  2798. #define more_example_usage \
  2799. "$ dmesg | more\n"
  2800. #define mount_trivial_usage \
  2801. "[OPTIONS] [-o OPTS] DEVICE NODE"
  2802. #define mount_full_usage "\n\n" \
  2803. "Mount a filesystem. Filesystem autodetection requires /proc.\n" \
  2804. "\nOptions:" \
  2805. "\n -a Mount all filesystems in fstab" \
  2806. IF_FEATURE_MOUNT_FAKE( \
  2807. IF_FEATURE_MTAB_SUPPORT( \
  2808. "\n -f Update /etc/mtab, but don't mount" \
  2809. ) \
  2810. IF_NOT_FEATURE_MTAB_SUPPORT( \
  2811. "\n -f Dry run" \
  2812. ) \
  2813. ) \
  2814. IF_FEATURE_MOUNT_HELPERS( \
  2815. "\n -i Don't run mount helper" \
  2816. ) \
  2817. IF_FEATURE_MTAB_SUPPORT( \
  2818. "\n -n Don't update /etc/mtab" \
  2819. ) \
  2820. "\n -r Read-only mount" \
  2821. "\n -w Read-write mount (default)" \
  2822. "\n -t FSTYPE Filesystem type" \
  2823. "\n -O OPT Mount only filesystems with option OPT (-a only)" \
  2824. "\n-o OPT:" \
  2825. IF_FEATURE_MOUNT_LOOP( \
  2826. "\n loop Ignored (loop devices are autodetected)" \
  2827. ) \
  2828. IF_FEATURE_MOUNT_FLAGS( \
  2829. "\n [a]sync Writes are [a]synchronous" \
  2830. "\n [no]atime Disable/enable updates to inode access times" \
  2831. "\n [no]diratime Disable/enable atime updates to directories" \
  2832. "\n [no]relatime Disable/enable atime updates relative to modification time" \
  2833. "\n [no]dev (Dis)allow use of special device files" \
  2834. "\n [no]exec (Dis)allow use of executable files" \
  2835. "\n [no]suid (Dis)allow set-user-id-root programs" \
  2836. "\n [r]shared Convert [recursively] to a shared subtree" \
  2837. "\n [r]slave Convert [recursively] to a slave subtree" \
  2838. "\n [r]private Convert [recursively] to a private subtree" \
  2839. "\n [un]bindable Make mount point [un]able to be bind mounted" \
  2840. "\n bind Bind a file or directory to another location" \
  2841. "\n move Relocate an existing mount point" \
  2842. ) \
  2843. "\n remount Remount a mounted filesystem, changing flags" \
  2844. "\n ro/rw Same as -r/-w" \
  2845. "\n" \
  2846. "\nThere are filesystem-specific -o flags." \
  2847. #define mount_example_usage \
  2848. "$ mount\n" \
  2849. "/dev/hda3 on / type minix (rw)\n" \
  2850. "proc on /proc type proc (rw)\n" \
  2851. "devpts on /dev/pts type devpts (rw)\n" \
  2852. "$ mount /dev/fd0 /mnt -t msdos -o ro\n" \
  2853. "$ mount /tmp/diskimage /opt -t ext2 -o loop\n" \
  2854. "$ mount cd_image.iso mydir\n"
  2855. #define mount_notes_usage \
  2856. "Returns 0 for success, number of failed mounts for -a, or errno for one mount."
  2857. #define mountpoint_trivial_usage \
  2858. "[-q] <[-dn] DIR | -x DEVICE>"
  2859. #define mountpoint_full_usage "\n\n" \
  2860. "Check if the directory is a mountpoint\n" \
  2861. "\nOptions:" \
  2862. "\n -q Quiet" \
  2863. "\n -d Print major/minor device number of the filesystem" \
  2864. "\n -n Print device name of the filesystem" \
  2865. "\n -x Print major/minor device number of the blockdevice" \
  2866. #define mountpoint_example_usage \
  2867. "$ mountpoint /proc\n" \
  2868. "/proc is not a mountpoint\n" \
  2869. "$ mountpoint /sys\n" \
  2870. "/sys is a mountpoint\n"
  2871. #define mt_trivial_usage \
  2872. "[-f device] opcode value"
  2873. #define mt_full_usage "\n\n" \
  2874. "Control magnetic tape drive operation\n" \
  2875. "\n" \
  2876. "Available Opcodes:\n" \
  2877. "\n" \
  2878. "bsf bsfm bsr bss datacompression drvbuffer eof eom erase\n" \
  2879. "fsf fsfm fsr fss load lock mkpart nop offline ras1 ras2\n" \
  2880. "ras3 reset retension rewind rewoffline seek setblk setdensity\n" \
  2881. "setpart tell unload unlock weof wset" \
  2882. #define mv_trivial_usage \
  2883. "[OPTIONS] SOURCE DEST\n" \
  2884. "or: mv [OPTIONS] SOURCE... DIRECTORY"
  2885. #define mv_full_usage "\n\n" \
  2886. "Rename SOURCE to DEST, or move SOURCE(s) to DIRECTORY\n" \
  2887. "\nOptions:" \
  2888. "\n -f Don't prompt before overwriting" \
  2889. "\n -i Interactive, prompt before overwrite" \
  2890. #define mv_example_usage \
  2891. "$ mv /tmp/foo /bin/bar\n"
  2892. #define nameif_trivial_usage \
  2893. "[-s] [-c FILE] [{IFNAME MACADDR}]"
  2894. #define nameif_full_usage "\n\n" \
  2895. "Rename network interface while it in the down state\n" \
  2896. "\nOptions:" \
  2897. "\n -c FILE Use configuration file (default: /etc/mactab)" \
  2898. "\n -s Use syslog (LOCAL0 facility)" \
  2899. "\n IFNAME MACADDR new_interface_name interface_mac_address" \
  2900. #define nameif_example_usage \
  2901. "$ nameif -s dmz0 00:A0:C9:8C:F6:3F\n" \
  2902. " or\n" \
  2903. "$ nameif -c /etc/my_mactab_file\n" \
  2904. #if !ENABLE_DESKTOP
  2905. #if ENABLE_NC_SERVER || ENABLE_NC_EXTRA
  2906. #define NC_OPTIONS_STR "\n\nOptions:"
  2907. #else
  2908. #define NC_OPTIONS_STR
  2909. #endif
  2910. #define nc_trivial_usage \
  2911. IF_NC_EXTRA("[-iN] [-wN] ")IF_NC_SERVER("[-l] [-p PORT] ") \
  2912. "["IF_NC_EXTRA("-f FILENAME|")"IPADDR PORT]"IF_NC_EXTRA(" [-e PROG]")
  2913. #define nc_full_usage "\n\n" \
  2914. "Open a pipe to IP:port" IF_NC_EXTRA(" or file") \
  2915. NC_OPTIONS_STR \
  2916. IF_NC_EXTRA( \
  2917. "\n -e PROG Run PROG after connect" \
  2918. "\n -i SEC Delay interval for lines sent" \
  2919. "\n -w SEC Timeout for connect" \
  2920. "\n -f FILE Use file (ala /dev/ttyS0) instead of network" \
  2921. ) \
  2922. IF_NC_SERVER( \
  2923. "\n -l Listen mode, for inbound connects" \
  2924. IF_NC_EXTRA( \
  2925. "\n (use -l twice with -e for persistent server)") \
  2926. "\n -p PORT Local port" \
  2927. )
  2928. #define nc_notes_usage "" \
  2929. IF_NC_EXTRA( \
  2930. "To use netcat as a terminal emulator on a serial port:\n\n" \
  2931. "$ stty 115200 -F /dev/ttyS0\n" \
  2932. "$ stty raw -echo -ctlecho && nc -f /dev/ttyS0\n" \
  2933. )
  2934. #define nc_example_usage \
  2935. "$ nc foobar.somedomain.com 25\n" \
  2936. "220 foobar ESMTP Exim 3.12 #1 Sat, 15 Apr 2000 00:03:02 -0600\n" \
  2937. "help\n" \
  2938. "214-Commands supported:\n" \
  2939. "214- HELO EHLO MAIL RCPT DATA AUTH\n" \
  2940. "214 NOOP QUIT RSET HELP\n" \
  2941. "quit\n" \
  2942. "221 foobar closing connection\n"
  2943. #else /* DESKTOP nc - much more compatible with nc 1.10 */
  2944. #define nc_trivial_usage \
  2945. "[OPTIONS] HOST PORT - connect" \
  2946. IF_NC_SERVER("\n" \
  2947. "nc [OPTIONS] -l -p PORT [HOST] [PORT] - listen")
  2948. #define nc_full_usage "\n\n" \
  2949. "Options:" \
  2950. "\n -e PROG Run PROG after connect (must be last)" \
  2951. IF_NC_SERVER( \
  2952. "\n -l Listen mode, for inbound connects" \
  2953. ) \
  2954. "\n -n Don't do DNS resolution" \
  2955. "\n -s ADDR Local address" \
  2956. "\n -p PORT Local port" \
  2957. "\n -u UDP mode" \
  2958. "\n -v Verbose" \
  2959. "\n -w SEC Timeout for connects and final net reads" \
  2960. IF_NC_EXTRA( \
  2961. "\n -i SEC Delay interval for lines sent" /* ", ports scanned" */ \
  2962. "\n -o FILE Hex dump traffic" \
  2963. "\n -z Zero-I/O mode (scanning)" \
  2964. ) \
  2965. /* "\n -r Randomize local and remote ports" */
  2966. /* "\n -g gateway Source-routing hop point[s], up to 8" */
  2967. /* "\n -G num Source-routing pointer: 4, 8, 12, ..." */
  2968. /* "\nport numbers can be individual or ranges: lo-hi [inclusive]" */
  2969. /* -e PROG can take ARGS too: "nc ... -e ls -l", but we don't document it
  2970. * in help text: nc 1.10 does not allow that. We don't want to entice
  2971. * users to use this incompatibility */
  2972. #endif
  2973. #define netstat_trivial_usage \
  2974. "[-laentuwxr"IF_FEATURE_NETSTAT_WIDE("W")IF_FEATURE_NETSTAT_PRG("p")"]"
  2975. #define netstat_full_usage "\n\n" \
  2976. "Display networking information\n" \
  2977. "\nOptions:" \
  2978. "\n -l Display listening server sockets" \
  2979. "\n -a Display all sockets (default: connected)" \
  2980. "\n -e Display other/more information" \
  2981. "\n -n Don't resolve names" \
  2982. "\n -t Tcp sockets" \
  2983. "\n -u Udp sockets" \
  2984. "\n -w Raw sockets" \
  2985. "\n -x Unix sockets" \
  2986. "\n -r Display routing table" \
  2987. IF_FEATURE_NETSTAT_WIDE( \
  2988. "\n -W Display with no column truncation" \
  2989. ) \
  2990. IF_FEATURE_NETSTAT_PRG( \
  2991. "\n -p Display PID/Program name for sockets" \
  2992. )
  2993. #define nice_trivial_usage \
  2994. "[-n ADJUST] [PROG ARGS]"
  2995. #define nice_full_usage "\n\n" \
  2996. "Run PROG with modified scheduling priority\n" \
  2997. "\nOptions:" \
  2998. "\n -n ADJUST Adjust priority by ADJUST" \
  2999. #define nmeter_trivial_usage \
  3000. "format_string"
  3001. #define nmeter_full_usage "\n\n" \
  3002. "Monitor system in real time\n\n" \
  3003. "Format specifiers:\n" \
  3004. " %Nc or %[cN] Monitor CPU. N - bar size, default 10\n" \
  3005. " (displays: S:system U:user N:niced D:iowait I:irq i:softirq)\n" \
  3006. " %[niface] Monitor network interface 'iface'\n" \
  3007. " %m Monitor allocated memory\n" \
  3008. " %[mf] Monitor free memory\n" \
  3009. " %[mt] Monitor total memory\n" \
  3010. " %s Monitor allocated swap\n" \
  3011. " %f Monitor number of used file descriptors\n" \
  3012. " %Ni Monitor total/specific IRQ rate\n" \
  3013. " %x Monitor context switch rate\n" \
  3014. " %p Monitor forks\n" \
  3015. " %[pn] Monitor # of processes\n" \
  3016. " %b Monitor block io\n" \
  3017. " %Nt Show time (with N decimal points)\n" \
  3018. " %Nd Milliseconds between updates (default:1000)\n" \
  3019. " %r Print <cr> instead of <lf> at EOL" \
  3020. #define nmeter_example_usage \
  3021. "nmeter '%250d%t %20c int %i bio %b mem %m forks%p'"
  3022. #define nohup_trivial_usage \
  3023. "PROG ARGS"
  3024. #define nohup_full_usage "\n\n" \
  3025. "Run PROG immune to hangups, with output to a non-tty"
  3026. #define nohup_example_usage \
  3027. "$ nohup make &"
  3028. #define nslookup_trivial_usage \
  3029. "[HOST] [SERVER]"
  3030. #define nslookup_full_usage "\n\n" \
  3031. "Query the nameserver for the IP address of the given HOST\n" \
  3032. "optionally using a specified DNS server"
  3033. #define nslookup_example_usage \
  3034. "$ nslookup localhost\n" \
  3035. "Server: default\n" \
  3036. "Address: default\n" \
  3037. "\n" \
  3038. "Name: debian\n" \
  3039. "Address: 127.0.0.1\n"
  3040. #define ntpd_trivial_usage \
  3041. "[-dnqwl] [-S PROG] [-p PEER]..."
  3042. #define ntpd_full_usage "\n\n" \
  3043. "NTP client/server\n" \
  3044. "\nOptions:" \
  3045. "\n -d Verbose" \
  3046. "\n -n Do not daemonize" \
  3047. "\n -q Quit after clock is set" \
  3048. /* -N exists for mostly compat reasons, thus not essential to inform */ \
  3049. /* the user that it exists: user may use nice as well */ \
  3050. /* "\n -N Run at high priority" */ \
  3051. "\n -w Do not set time (only query peers), implies -n" \
  3052. "\n -l Run as server on port 123" \
  3053. "\n -S PROG Run PROG after stepping time, stratum change, and every 11 mins" \
  3054. "\n -p PEER Obtain time from PEER (may be repeated)" \
  3055. #define od_trivial_usage \
  3056. "[-aBbcDdeFfHhIiLlOovXx] " IF_DESKTOP("[-t TYPE] ") "[FILE]"
  3057. #define od_full_usage "\n\n" \
  3058. "Write an unambiguous representation, octal bytes by default, of FILE\n" \
  3059. "(or stdin) to stdout"
  3060. #define openvt_trivial_usage \
  3061. "[-c N] [-sw] [PROG ARGS]"
  3062. #define openvt_full_usage "\n\n" \
  3063. "Start PROG on a new virtual terminal\n" \
  3064. "\nOptions:" \
  3065. "\n -c N Use specified VT" \
  3066. "\n -s Switch to the VT" \
  3067. /* "\n -l Run PROG as login shell (by prepending '-')" */ \
  3068. "\n -w Wait for PROG to exit" \
  3069. #define openvt_example_usage \
  3070. "openvt 2 /bin/ash\n"
  3071. /*
  3072. #define parse_trivial_usage \
  3073. "[-n MAXTOKENS] [-m MINTOKENS] [-d DELIMS] [-f FLAGS] FILE..."
  3074. #define parse_full_usage ""
  3075. */
  3076. #define passwd_trivial_usage \
  3077. "[OPTIONS] [USER]"
  3078. #define passwd_full_usage "\n\n" \
  3079. "Change USER's password. If no USER is specified,\n" \
  3080. "changes the password for the current user.\n" \
  3081. "\nOptions:" \
  3082. "\n -a Algorithm to use for password (des, md5)" /* ", sha1)" */ \
  3083. "\n -d Delete password for the account" \
  3084. "\n -l Lock (disable) account" \
  3085. "\n -u Unlock (re-enable) account" \
  3086. #define chpasswd_trivial_usage \
  3087. IF_LONG_OPTS("[--md5|--encrypted]") IF_NOT_LONG_OPTS("[-m|-e]")
  3088. #define chpasswd_full_usage "\n\n" \
  3089. "Read user:password from stdin and update /etc/passwd\n" \
  3090. "\nOptions:" \
  3091. IF_LONG_OPTS( \
  3092. "\n -e,--encrypted Supplied passwords are in encrypted form" \
  3093. "\n -m,--md5 Use MD5 encryption instead of DES" \
  3094. ) \
  3095. IF_NOT_LONG_OPTS( \
  3096. "\n -e Supplied passwords are in encrypted form" \
  3097. "\n -m Use MD5 encryption instead of DES" \
  3098. )
  3099. #define patch_trivial_usage \
  3100. "[OPTIONS] [ORIGFILE [PATCHFILE]]"
  3101. #define patch_full_usage "\n\n" \
  3102. IF_LONG_OPTS( \
  3103. " -p,--strip N Strip N leading components from file names" \
  3104. "\n -i,--input DIFF Read DIFF instead of stdin" \
  3105. "\n -R,--reverse Reverse patch" \
  3106. "\n -N,--forward Ignore already applied patches" \
  3107. "\n --dry-run Don't actually change files" \
  3108. ) \
  3109. IF_NOT_LONG_OPTS( \
  3110. " -p N Strip N leading components from file names" \
  3111. "\n -i DIFF Read DIFF instead of stdin" \
  3112. "\n -R Reverse patch" \
  3113. "\n -N Ignore already applied patches" \
  3114. )
  3115. #define patch_example_usage \
  3116. "$ patch -p1 < example.diff\n" \
  3117. "$ patch -p0 -i example.diff"
  3118. #define pgrep_trivial_usage \
  3119. "[-flnovx] [-s SID|-P PPID|PATTERN]"
  3120. #define pgrep_full_usage "\n\n" \
  3121. "Display process(es) selected by regex PATTERN\n" \
  3122. "\nOptions:" \
  3123. "\n -l Show command name too" \
  3124. "\n -f Match against entire command line" \
  3125. "\n -n Show the newest process only" \
  3126. "\n -o Show the oldest process only" \
  3127. "\n -v Negate the match" \
  3128. "\n -x Match whole name (not substring)" \
  3129. "\n -s Match session ID (0 for current)" \
  3130. "\n -P Match parent process ID" \
  3131. #if (ENABLE_FEATURE_PIDOF_SINGLE || ENABLE_FEATURE_PIDOF_OMIT)
  3132. #define pidof_trivial_usage \
  3133. "[OPTIONS] [NAME]..."
  3134. #define USAGE_PIDOF "\n\nOptions:"
  3135. #else
  3136. #define pidof_trivial_usage \
  3137. "[NAME]..."
  3138. #define USAGE_PIDOF /* none */
  3139. #endif
  3140. #define pidof_full_usage "\n\n" \
  3141. "List PIDs of all processes with names that match NAMEs" \
  3142. USAGE_PIDOF \
  3143. IF_FEATURE_PIDOF_SINGLE( \
  3144. "\n -s Show only one PID") \
  3145. IF_FEATURE_PIDOF_OMIT( \
  3146. "\n -o PID Omit given pid" \
  3147. "\n Use %PPID to omit pid of pidof's parent") \
  3148. #define pidof_example_usage \
  3149. "$ pidof init\n" \
  3150. "1\n" \
  3151. IF_FEATURE_PIDOF_OMIT( \
  3152. "$ pidof /bin/sh\n20351 5973 5950\n") \
  3153. IF_FEATURE_PIDOF_OMIT( \
  3154. "$ pidof /bin/sh -o %PPID\n20351 5950")
  3155. #if !ENABLE_FEATURE_FANCY_PING
  3156. #define ping_trivial_usage \
  3157. "host"
  3158. #define ping_full_usage "\n\n" \
  3159. "Send ICMP ECHO_REQUEST packets to network hosts"
  3160. #define ping6_trivial_usage \
  3161. "host"
  3162. #define ping6_full_usage "\n\n" \
  3163. "Send ICMP ECHO_REQUEST packets to network hosts"
  3164. #else
  3165. #define ping_trivial_usage \
  3166. "[OPTIONS] HOST"
  3167. #define ping_full_usage "\n\n" \
  3168. "Send ICMP ECHO_REQUEST packets to network hosts\n" \
  3169. "\nOptions:" \
  3170. "\n -4, -6 Force IP or IPv6 name resolution" \
  3171. "\n -c CNT Send only CNT pings" \
  3172. "\n -s SIZE Send SIZE data bytes in packets (default:56)" \
  3173. "\n -I IFACE/IP Use interface or IP address as source" \
  3174. "\n -W SEC Seconds to wait for the first response (default:10)" \
  3175. "\n (after all -c CNT packets are sent)" \
  3176. "\n -w SEC Seconds until ping exits (default:infinite)" \
  3177. "\n (can exit earlier with -c CNT)" \
  3178. "\n -q Quiet, only displays output at start" \
  3179. "\n and when finished" \
  3180. #define ping6_trivial_usage \
  3181. "[OPTIONS] HOST"
  3182. #define ping6_full_usage "\n\n" \
  3183. "Send ICMP ECHO_REQUEST packets to network hosts\n" \
  3184. "\nOptions:" \
  3185. "\n -c CNT Send only CNT pings" \
  3186. "\n -s SIZE Send SIZE data bytes in packets (default:56)" \
  3187. "\n -I IFACE/IP Use interface or IP address as source" \
  3188. "\n -q Quiet, only displays output at start" \
  3189. "\n and when finished" \
  3190. #endif
  3191. #define ping_example_usage \
  3192. "$ ping localhost\n" \
  3193. "PING slag (127.0.0.1): 56 data bytes\n" \
  3194. "64 bytes from 127.0.0.1: icmp_seq=0 ttl=255 time=20.1 ms\n" \
  3195. "\n" \
  3196. "--- debian ping statistics ---\n" \
  3197. "1 packets transmitted, 1 packets received, 0% packet loss\n" \
  3198. "round-trip min/avg/max = 20.1/20.1/20.1 ms\n"
  3199. #define ping6_example_usage \
  3200. "$ ping6 ip6-localhost\n" \
  3201. "PING ip6-localhost (::1): 56 data bytes\n" \
  3202. "64 bytes from ::1: icmp6_seq=0 ttl=64 time=20.1 ms\n" \
  3203. "\n" \
  3204. "--- ip6-localhost ping statistics ---\n" \
  3205. "1 packets transmitted, 1 packets received, 0% packet loss\n" \
  3206. "round-trip min/avg/max = 20.1/20.1/20.1 ms\n"
  3207. #define pipe_progress_trivial_usage NOUSAGE_STR
  3208. #define pipe_progress_full_usage ""
  3209. #define pivot_root_trivial_usage \
  3210. "NEW_ROOT PUT_OLD"
  3211. #define pivot_root_full_usage "\n\n" \
  3212. "Move the current root file system to PUT_OLD and make NEW_ROOT\n" \
  3213. "the new root file system"
  3214. #define pkill_trivial_usage \
  3215. "[-l|-SIGNAL] [-fnovx] [-s SID|-P PPID|PATTERN]"
  3216. #define pkill_full_usage "\n\n" \
  3217. "Send a signal to process(es) selected by regex PATTERN\n" \
  3218. "\nOptions:" \
  3219. "\n -l List all signals" \
  3220. "\n -f Match against entire command line" \
  3221. "\n -n Signal the newest process only" \
  3222. "\n -o Signal the oldest process only" \
  3223. "\n -v Negate the match" \
  3224. "\n -x Match whole name (not substring)" \
  3225. "\n -s Match session ID (0 for current)" \
  3226. "\n -P Match parent process ID" \
  3227. #define popmaildir_trivial_usage \
  3228. "[OPTIONS] MAILDIR [CONN_HELPER ARGS]"
  3229. #define popmaildir_full_usage "\n\n" \
  3230. "Fetch content of remote mailbox to local maildir\n" \
  3231. "\nOptions:" \
  3232. /* "\n -b Binary mode. Ignored" */ \
  3233. /* "\n -d Debug. Ignored" */ \
  3234. /* "\n -m Show used memory. Ignored" */ \
  3235. /* "\n -V Show version. Ignored" */ \
  3236. /* "\n -c Use tcpclient. Ignored" */ \
  3237. /* "\n -a Use APOP protocol. Implied. If server supports APOP -> use it" */ \
  3238. "\n -s Skip authorization" \
  3239. "\n -T Get messages with TOP instead of RETR" \
  3240. "\n -k Keep retrieved messages on the server" \
  3241. "\n -t SEC Network timeout" \
  3242. IF_FEATURE_POPMAILDIR_DELIVERY( \
  3243. "\n -F \"PROG ARGS\" Filter program (may be repeated)" \
  3244. "\n -M \"PROG ARGS\" Delivery program" \
  3245. ) \
  3246. "\n" \
  3247. "\nFetch from plain POP3 server:" \
  3248. "\npopmaildir -k DIR nc pop3.server.com 110 <user_and_pass.txt" \
  3249. "\nFetch from SSLed POP3 server and delete fetched emails:" \
  3250. "\npopmaildir DIR -- openssl s_client -quiet -connect pop3.server.com:995 <user_and_pass.txt"
  3251. /* "\n -R BYTES Remove old messages on the server >= BYTES. Ignored" */
  3252. /* "\n -Z N1-N2 Remove messages from N1 to N2 (dangerous). Ignored" */
  3253. /* "\n -L BYTES Don't retrieve new messages >= BYTES. Ignored" */
  3254. /* "\n -H LINES Type first LINES of a message. Ignored" */
  3255. #define popmaildir_example_usage \
  3256. "$ popmaildir -k ~/Maildir -- nc pop.drvv.ru 110 [<password_file]\n" \
  3257. "$ popmaildir ~/Maildir -- openssl s_client -quiet -connect pop.gmail.com:995 [<password_file]\n"
  3258. #define poweroff_trivial_usage \
  3259. "[-d DELAY] [-n] [-f]"
  3260. #define poweroff_full_usage "\n\n" \
  3261. "Halt and shut off power\n" \
  3262. "\nOptions:" \
  3263. "\n -d Delay interval for halting" \
  3264. "\n -n Do not sync" \
  3265. "\n -f Force power off (don't go through init)" \
  3266. #define printenv_trivial_usage \
  3267. "[VARIABLE]..."
  3268. #define printenv_full_usage "\n\n" \
  3269. "Print environment VARIABLEs.\n" \
  3270. "If no VARIABLE specified, print all."
  3271. #define printf_trivial_usage \
  3272. "FORMAT [ARGUMENT]..."
  3273. #define printf_full_usage "\n\n" \
  3274. "Format and print ARGUMENT(s) according to FORMAT,\n" \
  3275. "where FORMAT controls the output exactly as in C printf"
  3276. #define printf_example_usage \
  3277. "$ printf \"Val=%d\\n\" 5\n" \
  3278. "Val=5\n"
  3279. #if ENABLE_DESKTOP
  3280. #define ps_trivial_usage \
  3281. ""
  3282. #define ps_full_usage "\n\n" \
  3283. "Report process status\n" \
  3284. "\nOptions:" \
  3285. "\n -o col1,col2=header Select columns for display" \
  3286. IF_FEATURE_SHOW_THREADS( \
  3287. "\n -T Show threads" \
  3288. )
  3289. #else /* !ENABLE_DESKTOP */
  3290. #if !ENABLE_SELINUX && !ENABLE_FEATURE_PS_WIDE
  3291. #define USAGE_PS "\nThis version of ps accepts no options"
  3292. #else
  3293. #define USAGE_PS "\nOptions:"
  3294. #endif
  3295. #define ps_trivial_usage \
  3296. ""
  3297. #define ps_full_usage "\n\n" \
  3298. "Report process status\n" \
  3299. USAGE_PS \
  3300. IF_SELINUX( \
  3301. "\n -Z Show selinux context" \
  3302. ) \
  3303. IF_FEATURE_PS_WIDE( \
  3304. "\n w Wide output" \
  3305. )
  3306. #endif /* ENABLE_DESKTOP */
  3307. #define ps_example_usage \
  3308. "$ ps\n" \
  3309. " PID Uid Gid State Command\n" \
  3310. " 1 root root S init\n" \
  3311. " 2 root root S [kflushd]\n" \
  3312. " 3 root root S [kupdate]\n" \
  3313. " 4 root root S [kpiod]\n" \
  3314. " 5 root root S [kswapd]\n" \
  3315. " 742 andersen andersen S [bash]\n" \
  3316. " 743 andersen andersen S -bash\n" \
  3317. " 745 root root S [getty]\n" \
  3318. " 2990 andersen andersen R ps\n" \
  3319. #define pscan_trivial_usage \
  3320. "[-cb] [-p MIN_PORT] [-P MAX_PORT] [-t TIMEOUT] [-T MIN_RTT] HOST"
  3321. #define pscan_full_usage "\n\n" \
  3322. "Scan a host, print all open ports\n" \
  3323. "\nOptions:" \
  3324. "\n -c Show closed ports too" \
  3325. "\n -b Show blocked ports too" \
  3326. "\n -p Scan from this port (default 1)" \
  3327. "\n -P Scan up to this port (default 1024)" \
  3328. "\n -t Timeout (default 5000 ms)" \
  3329. "\n -T Minimum rtt (default 5 ms, increase for congested hosts)" \
  3330. #define pwd_trivial_usage \
  3331. ""
  3332. #define pwd_full_usage "\n\n" \
  3333. "Print the full filename of the current working directory"
  3334. #define pwd_example_usage \
  3335. "$ pwd\n" \
  3336. "/root\n"
  3337. #define raidautorun_trivial_usage \
  3338. "DEVICE"
  3339. #define raidautorun_full_usage "\n\n" \
  3340. "Tell the kernel to automatically search and start RAID arrays"
  3341. #define raidautorun_example_usage \
  3342. "$ raidautorun /dev/md0"
  3343. #define rdate_trivial_usage \
  3344. "[-sp] HOST"
  3345. #define rdate_full_usage "\n\n" \
  3346. "Get and possibly set the system date and time from a remote HOST\n" \
  3347. "\nOptions:" \
  3348. "\n -s Set the system date and time (default)" \
  3349. "\n -p Print the date and time" \
  3350. #define rdev_trivial_usage \
  3351. ""
  3352. #define rdev_full_usage "\n\n" \
  3353. "Print the device node associated with the filesystem mounted at '/'"
  3354. #define rdev_example_usage \
  3355. "$ rdev\n" \
  3356. "/dev/mtdblock9 /\n"
  3357. #define readahead_trivial_usage \
  3358. "[FILE]..."
  3359. #define readahead_full_usage "\n\n" \
  3360. "Preload FILEs to RAM"
  3361. #define readlink_trivial_usage \
  3362. IF_FEATURE_READLINK_FOLLOW("[-fnv] ") "FILE"
  3363. #define readlink_full_usage "\n\n" \
  3364. "Display the value of a symlink" \
  3365. IF_FEATURE_READLINK_FOLLOW( "\n" \
  3366. "\nOptions:" \
  3367. "\n -f Canonicalize by following all symlinks" \
  3368. "\n -n Don't add newline" \
  3369. "\n -v Verbose" \
  3370. ) \
  3371. #define readprofile_trivial_usage \
  3372. "[OPTIONS]"
  3373. #define readprofile_full_usage "\n\n" \
  3374. "Options:" \
  3375. "\n -m mapfile (Default: /boot/System.map)" \
  3376. "\n -p profile (Default: /proc/profile)" \
  3377. "\n -M NUM Set the profiling multiplier to NUM" \
  3378. "\n -i Print only info about the sampling step" \
  3379. "\n -v Verbose" \
  3380. "\n -a Print all symbols, even if count is 0" \
  3381. "\n -b Print individual histogram-bin counts" \
  3382. "\n -s Print individual counters within functions" \
  3383. "\n -r Reset all the counters (root only)" \
  3384. "\n -n Disable byte order auto-detection" \
  3385. #define realpath_trivial_usage \
  3386. "FILE..."
  3387. #define realpath_full_usage "\n\n" \
  3388. "Return the absolute pathnames of given FILE"
  3389. #define reboot_trivial_usage \
  3390. "[-d DELAY] [-n] [-f]"
  3391. #define reboot_full_usage "\n\n" \
  3392. "Reboot the system\n" \
  3393. "\nOptions:" \
  3394. "\n -d Delay interval for rebooting" \
  3395. "\n -n No call to sync()" \
  3396. "\n -f Force reboot (don't go through init)" \
  3397. #define reformime_trivial_usage \
  3398. "[OPTIONS] [FILE]..."
  3399. #define reformime_full_usage "\n\n" \
  3400. "Parse MIME-encoded message\n" \
  3401. "\nOptions:" \
  3402. "\n -x PREFIX Extract content of MIME sections to files" \
  3403. "\n -X PROG ARGS Filter content of MIME sections through PROG" \
  3404. "\n Must be the last option" \
  3405. "\n" \
  3406. "\nOther options are silently ignored" \
  3407. #define renice_trivial_usage \
  3408. "{{-n INCREMENT} | PRIORITY} [[-p | -g | -u] ID...]"
  3409. #define renice_full_usage "\n\n" \
  3410. "Change priority of running processes\n" \
  3411. "\nOptions:" \
  3412. "\n -n Adjust current nice value (smaller is faster)" \
  3413. "\n -p Process id(s) (default)" \
  3414. "\n -g Process group id(s)" \
  3415. "\n -u Process user name(s) and/or id(s)" \
  3416. #define scriptreplay_trivial_usage \
  3417. "timingfile [typescript [divisor]]"
  3418. #define scriptreplay_full_usage "\n\n" \
  3419. "Play back typescripts, using timing information"
  3420. #define reset_trivial_usage \
  3421. ""
  3422. #define reset_full_usage "\n\n" \
  3423. "Reset the screen"
  3424. #define resize_trivial_usage \
  3425. ""
  3426. #define resize_full_usage "\n\n" \
  3427. "Resize the screen"
  3428. #define restorecon_trivial_usage \
  3429. "[-iFnRv] [-e EXCLUDEDIR]... [-o FILE] [-f FILE]"
  3430. #define restorecon_full_usage "\n\n" \
  3431. "Reset security contexts of files in pathname\n" \
  3432. "\n -i Ignore files that don't exist" \
  3433. "\n -f FILE File with list of files to process" \
  3434. "\n -e DIR Directory to exclude" \
  3435. "\n -R,-r Recurse" \
  3436. "\n -n Don't change any file labels" \
  3437. "\n -o FILE Save list of files with incorrect context" \
  3438. "\n -v Verbose" \
  3439. "\n -vv Show changed labels" \
  3440. "\n -F Force reset of context to match file_context" \
  3441. "\n for customizable files, or the user section," \
  3442. "\n if it has changed" \
  3443. #define rfkill_trivial_usage \
  3444. "COMMAND [INDEX|TYPE]"
  3445. #define rfkill_full_usage "\n\n" \
  3446. "Enable/disable wireless devices\n" \
  3447. "\nCommands:" \
  3448. "\n list [INDEX|TYPE] List current state" \
  3449. "\n block INDEX|TYPE Disable device" \
  3450. "\n unblock INDEX|TYPE Enable device" \
  3451. "\n" \
  3452. "\n TYPE: all, wlan(wifi), bluetooth, uwb(ultrawideband)," \
  3453. "\n wimax, wwan, gps, fm" \
  3454. #define rm_trivial_usage \
  3455. "[OPTIONS] FILE..."
  3456. #define rm_full_usage "\n\n" \
  3457. "Remove (unlink) FILEs\n" \
  3458. "\nOptions:" \
  3459. "\n -i Always prompt before removing" \
  3460. "\n -f Never prompt" \
  3461. "\n -R,-r Recurse" \
  3462. #define rm_example_usage \
  3463. "$ rm -rf /tmp/foo\n"
  3464. #define rmdir_trivial_usage \
  3465. "[OPTIONS] DIRECTORY..."
  3466. #define rmdir_full_usage "\n\n" \
  3467. "Remove DIRECTORY if it is empty\n" \
  3468. "\nOptions:" \
  3469. IF_FEATURE_RMDIR_LONG_OPTIONS( \
  3470. "\n -p|--parents Include parents" \
  3471. "\n --ignore-fail-on-non-empty" \
  3472. ) \
  3473. IF_NOT_FEATURE_RMDIR_LONG_OPTIONS( \
  3474. "\n -p Include parents" \
  3475. )
  3476. #define rmdir_example_usage \
  3477. "# rmdir /tmp/foo\n"
  3478. #define rmmod_trivial_usage \
  3479. "[OPTIONS] [MODULE]..."
  3480. #define rmmod_full_usage "\n\n" \
  3481. "Unload the specified kernel modules from the kernel\n" \
  3482. "\nOptions:" \
  3483. "\n -w Wait until the module is no longer used" \
  3484. "\n -f Force unloading" \
  3485. "\n -a Remove all unused modules (recursively)" \
  3486. #define rmmod_example_usage \
  3487. "$ rmmod tulip\n"
  3488. #define route_trivial_usage \
  3489. "[{add|del|delete}]"
  3490. #define route_full_usage "\n\n" \
  3491. "Edit kernel routing tables\n" \
  3492. "\nOptions:" \
  3493. "\n -n Don't resolve names" \
  3494. "\n -e Display other/more information" \
  3495. "\n -A inet" IF_FEATURE_IPV6("{6}") " Select address family" \
  3496. #define rpm_trivial_usage \
  3497. "-i PACKAGE.rpm; rpm -qp[ildc] PACKAGE.rpm"
  3498. #define rpm_full_usage "\n\n" \
  3499. "Manipulate RPM packages\n" \
  3500. "\nCommands:" \
  3501. "\n -i Install package" \
  3502. "\n -qp Query package" \
  3503. "\nOptions:" \
  3504. "\n -i Show information" \
  3505. "\n -l List contents" \
  3506. "\n -d List documents" \
  3507. "\n -c List config files" \
  3508. #define rpm2cpio_trivial_usage \
  3509. "package.rpm"
  3510. #define rpm2cpio_full_usage "\n\n" \
  3511. "Output a cpio archive of the rpm file"
  3512. #define rtcwake_trivial_usage \
  3513. "[-a | -l | -u] [-d DEV] [-m MODE] [-s SEC | -t TIME]"
  3514. #define rtcwake_full_usage "\n\n" \
  3515. "Enter a system sleep state until specified wakeup time\n" \
  3516. IF_LONG_OPTS( \
  3517. "\n -a,--auto Read clock mode from adjtime" \
  3518. "\n -l,--local Clock is set to local time" \
  3519. "\n -u,--utc Clock is set to UTC time" \
  3520. "\n -d,--device=DEV Specify the RTC device" \
  3521. "\n -m,--mode=MODE Set the sleep state (default: standby)" \
  3522. "\n -s,--seconds=SEC Set the timeout in SEC seconds from now" \
  3523. "\n -t,--time=TIME Set the timeout to TIME seconds from epoch" \
  3524. ) \
  3525. IF_NOT_LONG_OPTS( \
  3526. "\n -a Read clock mode from adjtime" \
  3527. "\n -l Clock is set to local time" \
  3528. "\n -u Clock is set to UTC time" \
  3529. "\n -d DEV Specify the RTC device" \
  3530. "\n -m MODE Set the sleep state (default: standby)" \
  3531. "\n -s SEC Set the timeout in SEC seconds from now" \
  3532. "\n -t TIME Set the timeout to TIME seconds from epoch" \
  3533. )
  3534. #define runcon_trivial_usage \
  3535. "[-c] [-u USER] [-r ROLE] [-t TYPE] [-l RANGE] PROG ARGS\n" \
  3536. "runcon CONTEXT PROG ARGS"
  3537. #define runcon_full_usage "\n\n" \
  3538. "Run PROG in a different security context\n" \
  3539. "\n CONTEXT Complete security context\n" \
  3540. IF_FEATURE_RUNCON_LONG_OPTIONS( \
  3541. "\n -c,--compute Compute process transition context before modifying" \
  3542. "\n -t,--type=TYPE Type (for same role as parent)" \
  3543. "\n -u,--user=USER User identity" \
  3544. "\n -r,--role=ROLE Role" \
  3545. "\n -l,--range=RNG Levelrange" \
  3546. ) \
  3547. IF_NOT_FEATURE_RUNCON_LONG_OPTIONS( \
  3548. "\n -c Compute process transition context before modifying" \
  3549. "\n -t TYPE Type (for same role as parent)" \
  3550. "\n -u USER User identity" \
  3551. "\n -r ROLE Role" \
  3552. "\n -l RNG Levelrange" \
  3553. )
  3554. #define run_parts_trivial_usage \
  3555. "[-t] "IF_FEATURE_RUN_PARTS_FANCY("[-l] ")"[-a ARG] [-u MASK] DIRECTORY"
  3556. #define run_parts_full_usage "\n\n" \
  3557. "Run a bunch of scripts in DIRECTORY\n" \
  3558. "\nOptions:" \
  3559. "\n -t Print what would be run, but don't actually run anything" \
  3560. "\n -a ARG Pass ARG as argument for every program" \
  3561. "\n -u MASK Set the umask to MASK before running every program" \
  3562. IF_FEATURE_RUN_PARTS_FANCY( \
  3563. "\n -l Print names of all matching files even if they are not executable" \
  3564. )
  3565. #define run_parts_example_usage \
  3566. "$ run-parts -a start /etc/init.d\n" \
  3567. "$ run-parts -a stop=now /etc/init.d\n\n" \
  3568. "Let's assume you have a script foo/dosomething:\n" \
  3569. "#!/bin/sh\n" \
  3570. "for i in $*; do eval $i; done; unset i\n" \
  3571. "case \"$1\" in\n" \
  3572. "start*) echo starting something;;\n" \
  3573. "stop*) set -x; shutdown -h $stop;;\n" \
  3574. "esac\n\n" \
  3575. "Running this yields:\n" \
  3576. "$run-parts -a stop=+4m foo/\n" \
  3577. "+ shutdown -h +4m"
  3578. #define runlevel_trivial_usage \
  3579. "[FILE]"
  3580. #define runlevel_full_usage "\n\n" \
  3581. "Find the current and previous system runlevel\n" \
  3582. "\n" \
  3583. "If no utmp FILE exists or if no runlevel record can be found,\n" \
  3584. "print \"unknown\""
  3585. #define runlevel_example_usage \
  3586. "$ runlevel /var/run/utmp\n" \
  3587. "N 2"
  3588. #define runsv_trivial_usage \
  3589. "DIR"
  3590. #define runsv_full_usage "\n\n" \
  3591. "Start and monitor a service and optionally an appendant log service"
  3592. #define runsvdir_trivial_usage \
  3593. "[-P] [-s SCRIPT] DIR"
  3594. #define runsvdir_full_usage "\n\n" \
  3595. "Start a runsv process for each subdirectory. If it exits, restart it.\n" \
  3596. "\n -P Put each runsv in a new session" \
  3597. "\n -s SCRIPT Run SCRIPT <signo> after signal is processed" \
  3598. #define rx_trivial_usage \
  3599. "FILE"
  3600. #define rx_full_usage "\n\n" \
  3601. "Receive a file using the xmodem protocol"
  3602. #define rx_example_usage \
  3603. "$ rx /tmp/foo\n"
  3604. #define script_trivial_usage \
  3605. "[-afq" IF_SCRIPTREPLAY("t") "] [-c PROG] [OUTFILE]"
  3606. #define script_full_usage "\n\n" \
  3607. "Options:" \
  3608. "\n -a Append output" \
  3609. "\n -c PROG Run PROG, not shell" \
  3610. "\n -f Flush output after each write" \
  3611. "\n -q Quiet" \
  3612. IF_SCRIPTREPLAY( \
  3613. "\n -t Send timing to stderr" \
  3614. )
  3615. #define sed_trivial_usage \
  3616. "[-efinr] SED_CMD [FILE]..."
  3617. #define sed_full_usage "\n\n" \
  3618. "Options:" \
  3619. "\n -e CMD Add CMD to sed commands to be executed" \
  3620. "\n -f FILE Add FILE contents to sed commands to be executed" \
  3621. "\n -i Edit files in-place (else sends result to stdout)" \
  3622. "\n -n Suppress automatic printing of pattern space" \
  3623. "\n -r Use extended regex syntax" \
  3624. "\n" \
  3625. "\nIf no -e or -f, the first non-option argument is the sed command string." \
  3626. "\nRemaining arguments are input files (stdin if none)."
  3627. #define sed_example_usage \
  3628. "$ echo \"foo\" | sed -e 's/f[a-zA-Z]o/bar/g'\n" \
  3629. "bar\n"
  3630. #define selinuxenabled_trivial_usage NOUSAGE_STR
  3631. #define selinuxenabled_full_usage ""
  3632. #define sendmail_trivial_usage \
  3633. "[OPTIONS] [RECIPIENT_EMAIL]..."
  3634. #define sendmail_full_usage "\n\n" \
  3635. "Read email from stdin and send it\n" \
  3636. "\nStandard options:" \
  3637. "\n -t Read additional recipients from message body" \
  3638. "\n -f sender Sender (required)" \
  3639. "\n -o options Various options. -oi implied, others are ignored" \
  3640. "\n -i -oi synonym. implied and ignored" \
  3641. "\n" \
  3642. "\nBusybox specific options:" \
  3643. "\n -w seconds Network timeout" \
  3644. "\n -H 'PROG ARGS' Run connection helper" \
  3645. "\n Examples:" \
  3646. "\n -H 'exec openssl s_client -quiet -tls1 -starttls smtp" \
  3647. "\n -connect smtp.gmail.com:25' <email.txt" \
  3648. "\n [4<username_and_passwd.txt | -au<username> -ap<password>]" \
  3649. "\n -H 'exec openssl s_client -quiet -tls1" \
  3650. "\n -connect smtp.gmail.com:465' <email.txt" \
  3651. "\n [4<username_and_passwd.txt | -au<username> -ap<password>]" \
  3652. "\n -S server[:port] Server" \
  3653. "\n -au<username> Username for AUTH LOGIN" \
  3654. "\n -ap<password> Password for AUTH LOGIN" \
  3655. "\n -am<method> Authentication method. Ignored. LOGIN is implied" \
  3656. "\n" \
  3657. "\nOther options are silently ignored; -oi -t is implied" \
  3658. IF_MAKEMIME( \
  3659. "\nUse makemime applet to create message with attachments" \
  3660. )
  3661. #define seq_trivial_usage \
  3662. "[-w] [-s SEP] [FIRST [INC]] LAST"
  3663. #define seq_full_usage "\n\n" \
  3664. "Print numbers from FIRST to LAST, in steps of INC.\n" \
  3665. "FIRST, INC default to 1.\n" \
  3666. "\nOptions:" \
  3667. "\n -w Pad to last with leading zeros" \
  3668. "\n -s SEP String separator" \
  3669. #define sestatus_trivial_usage \
  3670. "[-vb]"
  3671. #define sestatus_full_usage "\n\n" \
  3672. " -v Verbose" \
  3673. "\n -b Display current state of booleans" \
  3674. #define setconsole_trivial_usage \
  3675. "[-r" IF_FEATURE_SETCONSOLE_LONG_OPTIONS("|--reset") "] [DEVICE]"
  3676. #define setconsole_full_usage "\n\n" \
  3677. "Redirect system console output to DEVICE (default: /dev/tty)\n" \
  3678. "\nOptions:" \
  3679. "\n -r Reset output to /dev/console" \
  3680. #define setenforce_trivial_usage \
  3681. "[Enforcing | Permissive | 1 | 0]"
  3682. #define setenforce_full_usage ""
  3683. #define setfiles_trivial_usage \
  3684. "[-dnpqsvW] [-e DIR]... [-o FILE] [-r alt_root_path]" \
  3685. IF_FEATURE_SETFILES_CHECK_OPTION( \
  3686. " [-c policyfile] spec_file" \
  3687. ) \
  3688. " pathname"
  3689. #define setfiles_full_usage "\n\n" \
  3690. "Reset file contexts under pathname according to spec_file\n" \
  3691. IF_FEATURE_SETFILES_CHECK_OPTION( \
  3692. "\n -c FILE Check the validity of the contexts against the specified binary policy" \
  3693. ) \
  3694. "\n -d Show which specification matched each file" \
  3695. "\n -l Log changes in file labels to syslog" \
  3696. "\n -n Don't change any file labels" \
  3697. "\n -q Suppress warnings" \
  3698. "\n -r DIR Use an alternate root path" \
  3699. "\n -e DIR Exclude DIR" \
  3700. "\n -F Force reset of context to match file_context for customizable files" \
  3701. "\n -o FILE Save list of files with incorrect context" \
  3702. "\n -s Take a list of files from stdin (instead of command line)" \
  3703. "\n -v Show changes in file labels, if type or role are changing" \
  3704. "\n -vv Show changes in file labels, if type, role, or user are changing" \
  3705. "\n -W Display warnings about entries that had no matching files" \
  3706. #define setfont_trivial_usage \
  3707. "FONT [-m MAPFILE] [-C TTY]"
  3708. #define setfont_full_usage "\n\n" \
  3709. "Load a console font\n" \
  3710. "\nOptions:" \
  3711. "\n -m MAPFILE Load console screen map" \
  3712. "\n -C TTY Affect TTY instead of /dev/tty" \
  3713. #define setfont_example_usage \
  3714. "$ setfont -m koi8-r /etc/i18n/fontname\n"
  3715. #define setkeycodes_trivial_usage \
  3716. "SCANCODE KEYCODE..."
  3717. #define setkeycodes_full_usage "\n\n" \
  3718. "Set entries into the kernel's scancode-to-keycode map,\n" \
  3719. "allowing unusual keyboards to generate usable keycodes.\n\n" \
  3720. "SCANCODE may be either xx or e0xx (hexadecimal),\n" \
  3721. "and KEYCODE is given in decimal." \
  3722. #define setkeycodes_example_usage \
  3723. "$ setkeycodes e030 127\n"
  3724. #define setlogcons_trivial_usage \
  3725. "N"
  3726. #define setlogcons_full_usage "\n\n" \
  3727. "Redirect the kernel output to console N (0 for current)"
  3728. #define setsebool_trivial_usage \
  3729. "boolean value"
  3730. #define setsebool_full_usage "\n\n" \
  3731. "Change boolean setting"
  3732. #define setsid_trivial_usage \
  3733. "PROG ARGS"
  3734. #define setsid_full_usage "\n\n" \
  3735. "Run PROG in a new session. PROG will have no controlling terminal\n" \
  3736. "and will not be affected by keyboard signals (Ctrl-C etc).\n" \
  3737. "See setsid(2) for details." \
  3738. #define last_trivial_usage \
  3739. ""IF_FEATURE_LAST_FANCY("[-HW] [-f FILE]")
  3740. #define last_full_usage "\n\n" \
  3741. "Show listing of the last users that logged into the system" \
  3742. IF_FEATURE_LAST_FANCY( "\n" \
  3743. "\nOptions:" \
  3744. /* "\n -H Show header line" */ \
  3745. "\n -W Display with no host column truncation" \
  3746. "\n -f FILE Read from FILE instead of /var/log/wtmp" \
  3747. )
  3748. #define showkey_trivial_usage \
  3749. "[-a | -k | -s]"
  3750. #define showkey_full_usage "\n\n" \
  3751. "Show keys pressed\n" \
  3752. "\nOptions:" \
  3753. "\n -a Display decimal/octal/hex values of the keys" \
  3754. "\n -k Display interpreted keycodes (default)" \
  3755. "\n -s Display raw scan-codes" \
  3756. #define slattach_trivial_usage \
  3757. "[-cehmLF] [-s SPEED] [-p PROTOCOL] DEVICE"
  3758. #define slattach_full_usage "\n\n" \
  3759. "Attach network interface(s) to serial line(s)\n" \
  3760. "\nOptions:" \
  3761. "\n -p PROT Set protocol (slip, cslip, slip6, clisp6 or adaptive)" \
  3762. "\n -s SPD Set line speed" \
  3763. "\n -e Exit after initializing device" \
  3764. "\n -h Exit when the carrier is lost" \
  3765. "\n -c PROG Run PROG when the line is hung up" \
  3766. "\n -m Do NOT initialize the line in raw 8 bits mode" \
  3767. "\n -L Enable 3-wire operation" \
  3768. "\n -F Disable RTS/CTS flow control" \
  3769. #define sleep_trivial_usage \
  3770. IF_FEATURE_FANCY_SLEEP("[") "N" IF_FEATURE_FANCY_SLEEP("]...")
  3771. #define sleep_full_usage "\n\n" \
  3772. IF_NOT_FEATURE_FANCY_SLEEP("Pause for N seconds") \
  3773. IF_FEATURE_FANCY_SLEEP( \
  3774. "Pause for a time equal to the total of the args given, where each arg can\n" \
  3775. "have an optional suffix of (s)econds, (m)inutes, (h)ours, or (d)ays")
  3776. #define sleep_example_usage \
  3777. "$ sleep 2\n" \
  3778. "[2 second delay results]\n" \
  3779. IF_FEATURE_FANCY_SLEEP( \
  3780. "$ sleep 1d 3h 22m 8s\n" \
  3781. "[98528 second delay results]\n")
  3782. #define sort_trivial_usage \
  3783. "[-nru" \
  3784. IF_FEATURE_SORT_BIG("gMcszbdfimSTokt] [-o FILE] [-k start[.offset][opts][,end[.offset][opts]] [-t CHAR") \
  3785. "] [FILE]..."
  3786. #define sort_full_usage "\n\n" \
  3787. "Sort lines of text\n" \
  3788. "\nOptions:" \
  3789. IF_FEATURE_SORT_BIG( \
  3790. "\n -b Ignore leading blanks" \
  3791. "\n -c Check whether input is sorted" \
  3792. "\n -d Dictionary order (blank or alphanumeric only)" \
  3793. "\n -f Ignore case" \
  3794. "\n -g General numerical sort" \
  3795. "\n -i Ignore unprintable characters" \
  3796. "\n -k Sort key" \
  3797. "\n -M Sort month" \
  3798. ) \
  3799. "\n -n Sort numbers" \
  3800. IF_FEATURE_SORT_BIG( \
  3801. "\n -o Output to file" \
  3802. "\n -k Sort by key" \
  3803. "\n -t CHAR Key separator" \
  3804. ) \
  3805. "\n -r Reverse sort order" \
  3806. IF_FEATURE_SORT_BIG( \
  3807. "\n -s Stable (don't sort ties alphabetically)" \
  3808. ) \
  3809. "\n -u Suppress duplicate lines" \
  3810. IF_FEATURE_SORT_BIG( \
  3811. "\n -z Lines are terminated by NUL, not newline" \
  3812. "\n -mST Ignored for GNU compatibility") \
  3813. #define sort_example_usage \
  3814. "$ echo -e \"e\\nf\\nb\\nd\\nc\\na\" | sort\n" \
  3815. "a\n" \
  3816. "b\n" \
  3817. "c\n" \
  3818. "d\n" \
  3819. "e\n" \
  3820. "f\n" \
  3821. IF_FEATURE_SORT_BIG( \
  3822. "$ echo -e \"c 3\\nb 2\\nd 2\" | $SORT -k 2,2n -k 1,1r\n" \
  3823. "d 2\n" \
  3824. "b 2\n" \
  3825. "c 3\n" \
  3826. ) \
  3827. ""
  3828. #define split_trivial_usage \
  3829. "[OPTIONS] [INPUT [PREFIX]]"
  3830. #define split_full_usage "\n\n" \
  3831. "Options:" \
  3832. "\n -b n[k|m] Split by bytes" \
  3833. "\n -l n Split by lines" \
  3834. "\n -a n Use n letters as suffix" \
  3835. #define split_example_usage \
  3836. "$ split TODO foo\n" \
  3837. "$ cat TODO | split -a 2 -l 2 TODO_\n"
  3838. #define start_stop_daemon_trivial_usage \
  3839. "[OPTIONS] [-S|-K] ... [-- ARGS...]"
  3840. #define start_stop_daemon_full_usage "\n\n" \
  3841. "Search for matching processes, and then\n" \
  3842. "-K: stop all matching processes.\n" \
  3843. "-S: start a process unless a matching process is found.\n" \
  3844. IF_FEATURE_START_STOP_DAEMON_LONG_OPTIONS( \
  3845. "\nProcess matching:" \
  3846. "\n -u,--user USERNAME|UID Match only this user's processes" \
  3847. "\n -n,--name NAME Match processes with NAME" \
  3848. "\n in comm field in /proc/PID/stat" \
  3849. "\n -x,--exec EXECUTABLE Match processes with this command" \
  3850. "\n in /proc/PID/cmdline" \
  3851. "\n -p,--pidfile FILE Match a process with PID from the file" \
  3852. "\n All specified conditions must match" \
  3853. "\n-S only:" \
  3854. "\n -x,--exec EXECUTABLE Program to run" \
  3855. "\n -a,--startas NAME Zeroth argument" \
  3856. "\n -b,--background Background" \
  3857. IF_FEATURE_START_STOP_DAEMON_FANCY( \
  3858. "\n -N,--nicelevel N Change nice level" \
  3859. ) \
  3860. "\n -c,--chuid USER[:[GRP]] Change to user/group" \
  3861. "\n -m,--make-pidfile Write PID to the pidfile specified by -p" \
  3862. "\n-K only:" \
  3863. "\n -s,--signal SIG Signal to send" \
  3864. "\n -t,--test Match only, exit with 0 if a process is found" \
  3865. "\nOther:" \
  3866. IF_FEATURE_START_STOP_DAEMON_FANCY( \
  3867. "\n -o,--oknodo Exit with status 0 if nothing is done" \
  3868. "\n -v,--verbose Verbose" \
  3869. ) \
  3870. "\n -q,--quiet Quiet" \
  3871. ) \
  3872. IF_NOT_FEATURE_START_STOP_DAEMON_LONG_OPTIONS( \
  3873. "\nProcess matching:" \
  3874. "\n -u USERNAME|UID Match only this user's processes" \
  3875. "\n -n NAME Match processes with NAME" \
  3876. "\n in comm field in /proc/PID/stat" \
  3877. "\n -x EXECUTABLE Match processes with this command" \
  3878. "\n command in /proc/PID/cmdline" \
  3879. "\n -p FILE Match a process with PID from the file" \
  3880. "\n All specified conditions must match" \
  3881. "\n-S only:" \
  3882. "\n -x EXECUTABLE Program to run" \
  3883. "\n -a NAME Zeroth argument" \
  3884. "\n -b Background" \
  3885. IF_FEATURE_START_STOP_DAEMON_FANCY( \
  3886. "\n -N N Change nice level" \
  3887. ) \
  3888. "\n -c USER[:[GRP]] Change to user/group" \
  3889. "\n -m Write PID to the pidfile specified by -p" \
  3890. "\n-K only:" \
  3891. "\n -s SIG Signal to send" \
  3892. "\n -t Match only, exit with 0 if a process is found" \
  3893. "\nOther:" \
  3894. IF_FEATURE_START_STOP_DAEMON_FANCY( \
  3895. "\n -o Exit with status 0 if nothing is done" \
  3896. "\n -v Verbose" \
  3897. ) \
  3898. "\n -q Quiet" \
  3899. ) \
  3900. #define stat_trivial_usage \
  3901. "[OPTIONS] FILE..."
  3902. #define stat_full_usage "\n\n" \
  3903. "Display file (default) or filesystem status\n" \
  3904. "\nOptions:" \
  3905. IF_FEATURE_STAT_FORMAT( \
  3906. "\n -c fmt Use the specified format" \
  3907. ) \
  3908. "\n -f Display filesystem status" \
  3909. "\n -L Follow links" \
  3910. "\n -t Display info in terse form" \
  3911. IF_SELINUX( \
  3912. "\n -Z Print security context" \
  3913. ) \
  3914. IF_FEATURE_STAT_FORMAT( \
  3915. "\n\nValid format sequences for files:\n" \
  3916. " %a Access rights in octal\n" \
  3917. " %A Access rights in human readable form\n" \
  3918. " %b Number of blocks allocated (see %B)\n" \
  3919. " %B The size in bytes of each block reported by %b\n" \
  3920. " %d Device number in decimal\n" \
  3921. " %D Device number in hex\n" \
  3922. " %f Raw mode in hex\n" \
  3923. " %F File type\n" \
  3924. " %g Group ID of owner\n" \
  3925. " %G Group name of owner\n" \
  3926. " %h Number of hard links\n" \
  3927. " %i Inode number\n" \
  3928. " %n File name\n" \
  3929. " %N File name, with -> TARGET if symlink\n" \
  3930. " %o I/O block size\n" \
  3931. " %s Total size, in bytes\n" \
  3932. " %t Major device type in hex\n" \
  3933. " %T Minor device type in hex\n" \
  3934. " %u User ID of owner\n" \
  3935. " %U User name of owner\n" \
  3936. " %x Time of last access\n" \
  3937. " %X Time of last access as seconds since Epoch\n" \
  3938. " %y Time of last modification\n" \
  3939. " %Y Time of last modification as seconds since Epoch\n" \
  3940. " %z Time of last change\n" \
  3941. " %Z Time of last change as seconds since Epoch\n" \
  3942. "\nValid format sequences for file systems:\n" \
  3943. " %a Free blocks available to non-superuser\n" \
  3944. " %b Total data blocks in file system\n" \
  3945. " %c Total file nodes in file system\n" \
  3946. " %d Free file nodes in file system\n" \
  3947. " %f Free blocks in file system\n" \
  3948. IF_SELINUX( \
  3949. " %C Security context in selinux\n" \
  3950. ) \
  3951. " %i File System ID in hex\n" \
  3952. " %l Maximum length of filenames\n" \
  3953. " %n File name\n" \
  3954. " %s Block size (for faster transfer)\n" \
  3955. " %S Fundamental block size (for block counts)\n" \
  3956. " %t Type in hex\n" \
  3957. " %T Type in human readable form" \
  3958. ) \
  3959. #define strings_trivial_usage \
  3960. "[-afo] [-n LEN] [FILE]..."
  3961. #define strings_full_usage "\n\n" \
  3962. "Display printable strings in a binary file\n" \
  3963. "\nOptions:" \
  3964. "\n -a Scan whole file (default)" \
  3965. "\n -f Precede strings with filenames" \
  3966. "\n -n LEN At least LEN characters form a string (default 4)" \
  3967. "\n -o Precede strings with decimal offsets" \
  3968. #define stty_trivial_usage \
  3969. "[-a|g] [-F DEVICE] [SETTING]..."
  3970. #define stty_full_usage "\n\n" \
  3971. "Without arguments, prints baud rate, line discipline,\n" \
  3972. "and deviations from stty sane\n" \
  3973. "\nOptions:" \
  3974. "\n -F DEVICE Open device instead of stdin" \
  3975. "\n -a Print all current settings in human-readable form" \
  3976. "\n -g Print in stty-readable form" \
  3977. "\n [SETTING] See manpage" \
  3978. #define su_trivial_usage \
  3979. "[OPTIONS] [-] [USERNAME]"
  3980. #define su_full_usage "\n\n" \
  3981. "Change user id or become root\n" \
  3982. "\nOptions:" \
  3983. "\n -p,-m Preserve environment" \
  3984. "\n -c CMD Command to pass to 'sh -c'" \
  3985. "\n -s SH Shell to use instead of default shell" \
  3986. #define sulogin_trivial_usage \
  3987. "[-t N] [TTY]"
  3988. #define sulogin_full_usage "\n\n" \
  3989. "Single user login\n" \
  3990. "\nOptions:" \
  3991. "\n -t N Timeout" \
  3992. #define sum_trivial_usage \
  3993. "[-rs] [FILE]..."
  3994. #define sum_full_usage "\n\n" \
  3995. "Checksum and count the blocks in a file\n" \
  3996. "\nOptions:" \
  3997. "\n -r Use BSD sum algorithm (1K blocks)" \
  3998. "\n -s Use System V sum algorithm (512byte blocks)" \
  3999. #define sv_trivial_usage \
  4000. "[-v] [-w SEC] CMD SERVICE_DIR..."
  4001. #define sv_full_usage "\n\n" \
  4002. "Control services monitored by runsv supervisor.\n" \
  4003. "Commands (only first character is enough):\n" \
  4004. "\n" \
  4005. "status: query service status\n" \
  4006. "up: if service isn't running, start it. If service stops, restart it\n" \
  4007. "once: like 'up', but if service stops, don't restart it\n" \
  4008. "down: send TERM and CONT signals. If ./run exits, start ./finish\n" \
  4009. " if it exists. After it stops, don't restart service\n" \
  4010. "exit: send TERM and CONT signals to service and log service. If they exit,\n" \
  4011. " runsv exits too\n" \
  4012. "pause, cont, hup, alarm, interrupt, quit, 1, 2, term, kill: send\n" \
  4013. "STOP, CONT, HUP, ALRM, INT, QUIT, USR1, USR2, TERM, KILL signal to service" \
  4014. #define svlogd_trivial_usage \
  4015. "[-ttv] [-r C] [-R CHARS] [-l MATCHLEN] [-b BUFLEN] DIR..."
  4016. #define svlogd_full_usage "\n\n" \
  4017. "Continuously read log data from stdin, optionally\n" \
  4018. "filter log messages, and write the data to one or more automatically\n" \
  4019. "rotated logs" \
  4020. #define swapoff_trivial_usage \
  4021. "[-a] [DEVICE]"
  4022. #define swapoff_full_usage "\n\n" \
  4023. "Stop swapping on DEVICE\n" \
  4024. "\nOptions:" \
  4025. "\n -a Stop swapping on all swap devices" \
  4026. #define swapon_trivial_usage \
  4027. "[-a]" IF_FEATURE_SWAPON_PRI(" [-p PRI]") " [DEVICE]"
  4028. #define swapon_full_usage "\n\n" \
  4029. "Start swapping on DEVICE\n" \
  4030. "\nOptions:" \
  4031. "\n -a Start swapping on all swap devices" \
  4032. IF_FEATURE_SWAPON_PRI( \
  4033. "\n -p PRI Set swap device priority" \
  4034. ) \
  4035. #define switch_root_trivial_usage \
  4036. "[-c /dev/console] NEW_ROOT NEW_INIT [ARGS]"
  4037. #define switch_root_full_usage "\n\n" \
  4038. "Free initramfs and switch to another root fs:\n" \
  4039. "chroot to NEW_ROOT, delete all in /, move NEW_ROOT to /,\n" \
  4040. "execute NEW_INIT. PID must be 1. NEW_ROOT must be a mountpoint.\n" \
  4041. "\nOptions:" \
  4042. "\n -c DEV Reopen stdio to DEV after switch" \
  4043. #define sync_trivial_usage \
  4044. ""
  4045. #define sync_full_usage "\n\n" \
  4046. "Write all buffered blocks to disk"
  4047. #define fsync_trivial_usage \
  4048. "[OPTIONS] FILE..."
  4049. #define fsync_full_usage "\n\n" \
  4050. "Write files' buffered blocks to disk\n" \
  4051. "\nOptions:" \
  4052. "\n -d Avoid syncing metadata"
  4053. #define sysctl_trivial_usage \
  4054. "[OPTIONS] [VALUE]..."
  4055. #define sysctl_full_usage "\n\n" \
  4056. "Configure kernel parameters at runtime\n" \
  4057. "\nOptions:" \
  4058. "\n -n Don't print key names" \
  4059. "\n -e Don't warn about unknown keys" \
  4060. "\n -w Change sysctl setting" \
  4061. "\n -p FILE Load sysctl settings from FILE (default /etc/sysctl.conf)" \
  4062. "\n -a Display all values" \
  4063. "\n -A Display all values in table form" \
  4064. #define sysctl_example_usage \
  4065. "sysctl [-n] [-e] variable...\n" \
  4066. "sysctl [-n] [-e] -w variable=value...\n" \
  4067. "sysctl [-n] [-e] -a\n" \
  4068. "sysctl [-n] [-e] -p file (default /etc/sysctl.conf)\n" \
  4069. "sysctl [-n] [-e] -A\n"
  4070. #define syslogd_trivial_usage \
  4071. "[OPTIONS]"
  4072. #define syslogd_full_usage "\n\n" \
  4073. "System logging utility.\n" \
  4074. "This version of syslogd ignores /etc/syslog.conf\n" \
  4075. "\nOptions:" \
  4076. "\n -n Run in foreground" \
  4077. "\n -O FILE Log to given file (default:/var/log/messages)" \
  4078. "\n -l N Set local log level" \
  4079. "\n -S Smaller logging output" \
  4080. IF_FEATURE_ROTATE_LOGFILE( \
  4081. "\n -s SIZE Max size (KB) before rotate (default:200KB, 0=off)" \
  4082. "\n -b N N rotated logs to keep (default:1, max=99, 0=purge)") \
  4083. IF_FEATURE_REMOTE_LOG( \
  4084. "\n -R HOST[:PORT] Log to IP or hostname on PORT (default PORT=514/UDP)" \
  4085. "\n -L Log locally and via network (default is network only if -R)") \
  4086. IF_FEATURE_SYSLOGD_DUP( \
  4087. "\n -D Drop duplicates") \
  4088. IF_FEATURE_IPC_SYSLOG( \
  4089. "\n -C[size(KiB)] Log to shared mem buffer (read it using logread)") \
  4090. /* NB: -Csize shouldn't have space (because size is optional) */
  4091. /* "\n -m MIN Minutes between MARK lines (default:20, 0=off)" */
  4092. #define syslogd_example_usage \
  4093. "$ syslogd -R masterlog:514\n" \
  4094. "$ syslogd -R 192.168.1.1:601\n"
  4095. #define tac_trivial_usage \
  4096. "[FILE]..."
  4097. #define tac_full_usage "\n\n" \
  4098. "Concatenate FILEs and print them in reverse"
  4099. #define tar_trivial_usage \
  4100. "-[" IF_FEATURE_TAR_CREATE("c") "xt" IF_FEATURE_SEAMLESS_GZ("z") \
  4101. IF_FEATURE_SEAMLESS_BZ2("j") IF_FEATURE_SEAMLESS_LZMA("a") \
  4102. IF_FEATURE_SEAMLESS_Z("Z") IF_FEATURE_TAR_NOPRESERVE_TIME("m") "vO] " \
  4103. IF_FEATURE_TAR_FROM("[-X FILE] ") \
  4104. "[-f TARFILE] [-C DIR] [FILE]..."
  4105. #define tar_full_usage "\n\n" \
  4106. IF_FEATURE_TAR_CREATE("Create, extract, ") \
  4107. IF_NOT_FEATURE_TAR_CREATE("Extract ") \
  4108. "or list files from a tar file\n" \
  4109. "\nOptions:" \
  4110. IF_FEATURE_TAR_CREATE( \
  4111. "\n c Create" \
  4112. ) \
  4113. "\n x Extract" \
  4114. "\n t List" \
  4115. "\nArchive format selection:" \
  4116. IF_FEATURE_SEAMLESS_GZ( \
  4117. "\n z Filter the archive through gzip" \
  4118. ) \
  4119. IF_FEATURE_SEAMLESS_BZ2( \
  4120. "\n j Filter the archive through bzip2" \
  4121. ) \
  4122. IF_FEATURE_SEAMLESS_LZMA( \
  4123. "\n a Filter the archive through lzma" \
  4124. ) \
  4125. IF_FEATURE_SEAMLESS_Z( \
  4126. "\n Z Filter the archive through compress" \
  4127. ) \
  4128. IF_FEATURE_TAR_NOPRESERVE_TIME( \
  4129. "\n m Do not restore mtime" \
  4130. ) \
  4131. "\nFile selection:" \
  4132. "\n f Name of TARFILE or \"-\" for stdin" \
  4133. "\n O Extract to stdout" \
  4134. IF_FEATURE_TAR_FROM( \
  4135. IF_FEATURE_TAR_LONG_OPTIONS( \
  4136. "\n exclude File to exclude" \
  4137. ) \
  4138. "\n X File with names to exclude" \
  4139. ) \
  4140. "\n C Change to DIR before operation" \
  4141. "\n v Verbose" \
  4142. #define tar_example_usage \
  4143. "$ zcat /tmp/tarball.tar.gz | tar -xf -\n" \
  4144. "$ tar -cf /tmp/tarball.tar /usr/local\n"
  4145. #define taskset_trivial_usage \
  4146. "[-p] [MASK] [PID | PROG ARGS]"
  4147. #define taskset_full_usage "\n\n" \
  4148. "Set or get CPU affinity\n" \
  4149. "\nOptions:" \
  4150. "\n -p Operate on an existing PID" \
  4151. #define taskset_example_usage \
  4152. "$ taskset 0x7 ./dgemm_test&\n" \
  4153. "$ taskset -p 0x1 $!\n" \
  4154. "pid 4790's current affinity mask: 7\n" \
  4155. "pid 4790's new affinity mask: 1\n" \
  4156. "$ taskset 0x7 /bin/sh -c './taskset -p 0x1 $$'\n" \
  4157. "pid 6671's current affinity mask: 1\n" \
  4158. "pid 6671's new affinity mask: 1\n" \
  4159. "$ taskset -p 1\n" \
  4160. "pid 1's current affinity mask: 3\n"
  4161. #define tee_trivial_usage \
  4162. "[OPTIONS] [FILE]..."
  4163. #define tee_full_usage "\n\n" \
  4164. "Copy stdin to each FILE, and also to stdout\n" \
  4165. "\nOptions:" \
  4166. "\n -a Append to the given FILEs, don't overwrite" \
  4167. "\n -i Ignore interrupt signals (SIGINT)" \
  4168. #define tee_example_usage \
  4169. "$ echo \"Hello\" | tee /tmp/foo\n" \
  4170. "$ cat /tmp/foo\n" \
  4171. "Hello\n"
  4172. #if ENABLE_FEATURE_TELNET_AUTOLOGIN
  4173. #define telnet_trivial_usage \
  4174. "[-a] [-l USER] HOST [PORT]"
  4175. #define telnet_full_usage "\n\n" \
  4176. "Connect to telnet server\n" \
  4177. "\nOptions:" \
  4178. "\n -a Automatic login with $USER variable" \
  4179. "\n -l USER Automatic login as USER" \
  4180. #else
  4181. #define telnet_trivial_usage \
  4182. "HOST [PORT]"
  4183. #define telnet_full_usage "\n\n" \
  4184. "Connect to telnet server"
  4185. #endif
  4186. #define telnetd_trivial_usage \
  4187. "[OPTIONS]"
  4188. #define telnetd_full_usage "\n\n" \
  4189. "Handle incoming telnet connections" \
  4190. IF_NOT_FEATURE_TELNETD_STANDALONE(" via inetd") "\n" \
  4191. "\nOptions:" \
  4192. "\n -l LOGIN Exec LOGIN on connect" \
  4193. "\n -f ISSUE_FILE Display ISSUE_FILE instead of /etc/issue" \
  4194. "\n -K Close connection as soon as login exits" \
  4195. "\n (normally wait until all programs close slave pty)" \
  4196. IF_FEATURE_TELNETD_STANDALONE( \
  4197. "\n -p PORT Port to listen on" \
  4198. "\n -b ADDR[:PORT] Address to bind to" \
  4199. "\n -F Run in foreground" \
  4200. "\n -i Inetd mode" \
  4201. IF_FEATURE_TELNETD_INETD_WAIT( \
  4202. "\n -w SEC Inetd 'wait' mode, linger time SEC" \
  4203. "\n -S Log to syslog (implied by -i or without -F and -w)" \
  4204. ) \
  4205. )
  4206. /* "test --help" does not print help (POSIX compat), only "[ --help" does.
  4207. * We display "<applet> EXPRESSION ]" here (not "<applet> EXPRESSION")
  4208. * Unfortunately, it screws up generated BusyBox.html. TODO. */
  4209. #define test_trivial_usage \
  4210. "EXPRESSION ]"
  4211. #define test_full_usage "\n\n" \
  4212. "Check file types, compare values etc. Return a 0/1 exit code\n" \
  4213. "depending on logical value of EXPRESSION"
  4214. #define test_example_usage \
  4215. "$ test 1 -eq 2\n" \
  4216. "$ echo $?\n" \
  4217. "1\n" \
  4218. "$ test 1 -eq 1\n" \
  4219. "$ echo $?\n" \
  4220. "0\n" \
  4221. "$ [ -d /etc ]\n" \
  4222. "$ echo $?\n" \
  4223. "0\n" \
  4224. "$ [ -d /junk ]\n" \
  4225. "$ echo $?\n" \
  4226. "1\n"
  4227. #define tc_trivial_usage \
  4228. /*"[OPTIONS] "*/"OBJECT CMD [dev STRING]"
  4229. #define tc_full_usage "\n\n" \
  4230. "OBJECT: {qdisc|class|filter}\n" \
  4231. "CMD: {add|del|change|replace|show}\n" \
  4232. "\n" \
  4233. "qdisc [ handle QHANDLE ] [ root |"IF_FEATURE_TC_INGRESS(" ingress |")" parent CLASSID ]\n" \
  4234. /* "[ estimator INTERVAL TIME_CONSTANT ]\n" */ \
  4235. " [ [ QDISC_KIND ] [ help | OPTIONS ] ]\n" \
  4236. " QDISC_KIND := { [p|b]fifo | tbf | prio | cbq | red | etc. }\n" \
  4237. "qdisc show [ dev STRING ]"IF_FEATURE_TC_INGRESS(" [ingress]")"\n" \
  4238. "class [ classid CLASSID ] [ root | parent CLASSID ]\n" \
  4239. " [ [ QDISC_KIND ] [ help | OPTIONS ] ]\n" \
  4240. "class show [ dev STRING ] [ root | parent CLASSID ]\n" \
  4241. "filter [ pref PRIO ] [ protocol PROTO ]\n" \
  4242. /* "\t[ estimator INTERVAL TIME_CONSTANT ]\n" */ \
  4243. " [ root | classid CLASSID ] [ handle FILTERID ]\n" \
  4244. " [ [ FILTER_TYPE ] [ help | OPTIONS ] ]\n" \
  4245. "filter show [ dev STRING ] [ root | parent CLASSID ]"
  4246. #define tcpsvd_trivial_usage \
  4247. "[-hEv] [-c N] [-C N[:MSG]] [-b N] [-u USER] [-l NAME] IP PORT PROG"
  4248. /* with not-implemented options: */
  4249. /* "[-hpEvv] [-c N] [-C N[:MSG]] [-b N] [-u USER] [-l NAME] [-i DIR|-x CDB] [-t SEC] IP PORT PROG" */
  4250. #define tcpsvd_full_usage "\n\n" \
  4251. "Create TCP socket, bind to IP:PORT and listen\n" \
  4252. "for incoming connection. Run PROG for each connection.\n" \
  4253. "\n IP IP to listen on. '0' = all" \
  4254. "\n PORT Port to listen on" \
  4255. "\n PROG ARGS Program to run" \
  4256. "\n -l NAME Local hostname (else looks up local hostname in DNS)" \
  4257. "\n -u USER[:GRP] Change to user/group after bind" \
  4258. "\n -c N Handle up to N connections simultaneously" \
  4259. "\n -b N Allow a backlog of approximately N TCP SYNs" \
  4260. "\n -C N[:MSG] Allow only up to N connections from the same IP" \
  4261. "\n New connections from this IP address are closed" \
  4262. "\n immediately. MSG is written to the peer before close" \
  4263. "\n -h Look up peer's hostname" \
  4264. "\n -E Don't set up environment variables" \
  4265. "\n -v Verbose" \
  4266. #define udpsvd_trivial_usage \
  4267. "[-hEv] [-c N] [-u USER] [-l NAME] IP PORT PROG"
  4268. #define udpsvd_full_usage "\n\n" \
  4269. "Create UDP socket, bind to IP:PORT and wait\n" \
  4270. "for incoming packets. Run PROG for each packet,\n" \
  4271. "redirecting all further packets with same peer ip:port to it.\n" \
  4272. "\n IP IP to listen on. '0' = all" \
  4273. "\n PORT Port to listen on" \
  4274. "\n PROG ARGS Program to run" \
  4275. "\n -l NAME Local hostname (else looks up local hostname in DNS)" \
  4276. "\n -u USER[:GRP] Change to user/group after bind" \
  4277. "\n -c N Handle up to N connections simultaneously" \
  4278. "\n -h Look up peer's hostname" \
  4279. "\n -E Don't set up environment variables" \
  4280. "\n -v Verbose" \
  4281. #define tftp_trivial_usage \
  4282. "[OPTIONS] HOST [PORT]"
  4283. #define tftp_full_usage "\n\n" \
  4284. "Transfer a file from/to tftp server\n" \
  4285. "\nOptions:" \
  4286. "\n -l FILE Local FILE" \
  4287. "\n -r FILE Remote FILE" \
  4288. IF_FEATURE_TFTP_GET( \
  4289. "\n -g Get file" \
  4290. ) \
  4291. IF_FEATURE_TFTP_PUT( \
  4292. "\n -p Put file" \
  4293. ) \
  4294. IF_FEATURE_TFTP_BLOCKSIZE( \
  4295. "\n -b SIZE Transfer blocks of SIZE octets" \
  4296. )
  4297. #define tftpd_trivial_usage \
  4298. "[-cr] [-u USER] [DIR]"
  4299. #define tftpd_full_usage "\n\n" \
  4300. "Transfer a file on tftp client's request\n" \
  4301. "\n" \
  4302. "tftpd should be used as an inetd service.\n" \
  4303. "tftpd's line for inetd.conf:\n" \
  4304. " 69 dgram udp nowait root tftpd tftpd /files/to/serve\n" \
  4305. "It also can be ran from udpsvd:\n" \
  4306. " udpsvd -vE 0.0.0.0 69 tftpd /files/to/serve\n" \
  4307. "\nOptions:" \
  4308. "\n -r Prohibit upload" \
  4309. "\n -c Allow file creation via upload" \
  4310. "\n -u Access files as USER" \
  4311. #define time_trivial_usage \
  4312. "[OPTIONS] PROG ARGS"
  4313. #define time_full_usage "\n\n" \
  4314. "Run PROG, display resource usage when it exits\n" \
  4315. "\nOptions:" \
  4316. "\n -v Verbose" \
  4317. #define timeout_trivial_usage \
  4318. "[-t SECS] [-s SIG] PROG ARGS"
  4319. #define timeout_full_usage "\n\n" \
  4320. "Runs PROG. Sends SIG to it if it is not gone in SECS seconds.\n" \
  4321. "Defaults: SECS: 10, SIG: TERM." \
  4322. #define top_trivial_usage \
  4323. "[-b] [-nCOUNT] [-dSECONDS]" IF_FEATURE_TOPMEM(" [-m]")
  4324. #define top_full_usage "\n\n" \
  4325. "Provide a view of process activity in real time.\n" \
  4326. "Read the status of all processes from /proc each SECONDS\n" \
  4327. "and display a screenful of them." \
  4328. //TODO: add options and keyboard commands
  4329. #define touch_trivial_usage \
  4330. "[-c] [-d DATE] FILE [FILE]..."
  4331. #define touch_full_usage "\n\n" \
  4332. "Update the last-modified date on the given FILE[s]\n" \
  4333. "\nOptions:" \
  4334. "\n -c Don't create files" \
  4335. "\n -d DT Date/time to use" \
  4336. #define touch_example_usage \
  4337. "$ ls -l /tmp/foo\n" \
  4338. "/bin/ls: /tmp/foo: No such file or directory\n" \
  4339. "$ touch /tmp/foo\n" \
  4340. "$ ls -l /tmp/foo\n" \
  4341. "-rw-rw-r-- 1 andersen andersen 0 Apr 15 01:11 /tmp/foo\n"
  4342. #define tr_trivial_usage \
  4343. "[-cds] STRING1 [STRING2]"
  4344. #define tr_full_usage "\n\n" \
  4345. "Translate, squeeze, or delete characters from stdin, writing to stdout\n" \
  4346. "\nOptions:" \
  4347. "\n -c Take complement of STRING1" \
  4348. "\n -d Delete input characters coded STRING1" \
  4349. "\n -s Squeeze multiple output characters of STRING2 into one character" \
  4350. #define tr_example_usage \
  4351. "$ echo \"gdkkn vnqkc\" | tr [a-y] [b-z]\n" \
  4352. "hello world\n"
  4353. #define traceroute_trivial_usage \
  4354. "[-"IF_TRACEROUTE6("46")"FIldnrv] [-f 1ST_TTL] [-m MAXTTL] [-p PORT] [-q PROBES]\n" \
  4355. " [-s SRC_IP] [-t TOS] [-w WAIT_SEC] [-g GATEWAY] [-i IFACE]\n" \
  4356. " [-z PAUSE_MSEC] HOST [BYTES]"
  4357. #define traceroute_full_usage "\n\n" \
  4358. "Trace the route to HOST\n" \
  4359. "\nOptions:" \
  4360. IF_TRACEROUTE6( \
  4361. "\n -4, -6 Force IP or IPv6 name resolution" \
  4362. ) \
  4363. "\n -F Set the don't fragment bit" \
  4364. "\n -I Use ICMP ECHO instead of UDP datagrams" \
  4365. "\n -l Display the TTL value of the returned packet" \
  4366. "\n -d Set SO_DEBUG options to socket" \
  4367. "\n -n Print numeric addresses" \
  4368. "\n -r Bypass routing tables, send directly to HOST" \
  4369. "\n -v Verbose" \
  4370. "\n -m Max time-to-live (max number of hops)" \
  4371. "\n -p Base UDP port number used in probes" \
  4372. "\n (default 33434)" \
  4373. "\n -q Number of probes per TTL (default 3)" \
  4374. "\n -s IP address to use as the source address" \
  4375. "\n -t Type-of-service in probe packets (default 0)" \
  4376. "\n -w Time in seconds to wait for a response (default 3)" \
  4377. "\n -g Loose source route gateway (8 max)" \
  4378. #define traceroute6_trivial_usage \
  4379. "[-dnrv] [-m MAXTTL] [-p PORT] [-q PROBES]\n" \
  4380. " [-s SRC_IP] [-t TOS] [-w WAIT_SEC] [-i IFACE]\n" \
  4381. " HOST [BYTES]"
  4382. #define traceroute6_full_usage "\n\n" \
  4383. "Trace the route to HOST\n" \
  4384. "\nOptions:" \
  4385. "\n -d Set SO_DEBUG options to socket" \
  4386. "\n -n Print numeric addresses" \
  4387. "\n -r Bypass routing tables, send directly to HOST" \
  4388. "\n -v Verbose" \
  4389. "\n -m Max time-to-live (max number of hops)" \
  4390. "\n -p Base UDP port number used in probes" \
  4391. "\n (default is 33434)" \
  4392. "\n -q Number of probes per TTL (default 3)" \
  4393. "\n -s IP address to use as the source address" \
  4394. "\n -t Type-of-service in probe packets (default 0)" \
  4395. "\n -w Time in seconds to wait for a response (default 3)" \
  4396. #define true_trivial_usage \
  4397. ""
  4398. #define true_full_usage "\n\n" \
  4399. "Return an exit code of TRUE (0)"
  4400. #define true_example_usage \
  4401. "$ true\n" \
  4402. "$ echo $?\n" \
  4403. "0\n"
  4404. #define tty_trivial_usage \
  4405. ""
  4406. #define tty_full_usage "\n\n" \
  4407. "Print file name of stdin's terminal" \
  4408. IF_INCLUDE_SUSv2( "\n" \
  4409. "\nOptions:" \
  4410. "\n -s Print nothing, only return exit status" \
  4411. )
  4412. #define tty_example_usage \
  4413. "$ tty\n" \
  4414. "/dev/tty2\n"
  4415. #define ttysize_trivial_usage \
  4416. "[w] [h]"
  4417. #define ttysize_full_usage "\n\n" \
  4418. "Print dimension(s) of stdin's terminal, on error return 80x25"
  4419. #define tunctl_trivial_usage \
  4420. "[-f device] ([-t name] | -d name)" IF_FEATURE_TUNCTL_UG(" [-u owner] [-g group] [-b]")
  4421. #define tunctl_full_usage "\n\n" \
  4422. "Create or delete tun interfaces\n" \
  4423. "\nOptions:" \
  4424. "\n -f name tun device (/dev/net/tun)" \
  4425. "\n -t name Create iface 'name'" \
  4426. "\n -d name Delete iface 'name'" \
  4427. IF_FEATURE_TUNCTL_UG( \
  4428. "\n -u owner Set iface owner" \
  4429. "\n -g group Set iface group" \
  4430. "\n -b Brief output" \
  4431. )
  4432. #define tunctl_example_usage \
  4433. "# tunctl\n" \
  4434. "# tunctl -d tun0\n"
  4435. #define tune2fs_trivial_usage \
  4436. /* "[-c max-mounts-count] [-e errors-behavior] [-g group] " */ \
  4437. /* "[-i interval[d|m|w]] [-j] [-J journal-options] [-l] [-s sparse-flag] " */ \
  4438. /* "[-m reserved-blocks-percent] [-o [^]mount-options[,...]] " */ \
  4439. /* "[-r reserved-blocks-count] [-u user] [-C mount-count] " */ \
  4440. "[-L LABEL] " \
  4441. /* "[-M last-mounted-dir] [-O [^]feature[,...]] " */ \
  4442. /* "[-T last-check-time] [-U UUID] " */ \
  4443. "BLOCKDEV"
  4444. #define tune2fs_full_usage "\n\n" \
  4445. "Adjust filesystem options on ext[23] filesystems"
  4446. #define udhcpc_trivial_usage \
  4447. "[-fbnqvoCR] [-i IFACE] [-r IP] [-s PROG] [-p PIDFILE]\n" \
  4448. " [-H HOSTNAME] [-c CID] [-V VENDOR] [-O DHCP_OPT]..." IF_FEATURE_UDHCP_PORT(" [-P N]")
  4449. #define udhcpc_full_usage "\n" \
  4450. IF_LONG_OPTS( \
  4451. "\n -i,--interface IFACE Interface to use (default eth0)" \
  4452. "\n -p,--pidfile FILE Create pidfile" \
  4453. "\n -r,--request IP IP address to request" \
  4454. "\n -s,--script PROG Run PROG at DHCP events (default "CONFIG_UDHCPC_DEFAULT_SCRIPT")" \
  4455. "\n -t,--retries N Send up to N discover packets" \
  4456. "\n -T,--timeout N Pause between packets (default 3 seconds)" \
  4457. "\n -A,--tryagain N Wait N seconds after failure (default 20)" \
  4458. "\n -f,--foreground Run in foreground" \
  4459. USE_FOR_MMU( \
  4460. "\n -b,--background Background if lease is not obtained" \
  4461. ) \
  4462. "\n -S,--syslog Log to syslog too" \
  4463. "\n -n,--now Exit if lease is not obtained" \
  4464. "\n -q,--quit Exit after obtaining lease" \
  4465. "\n -R,--release Release IP on exit" \
  4466. IF_FEATURE_UDHCP_PORT( \
  4467. "\n -P,--client-port N Use port N (default 68)" \
  4468. ) \
  4469. IF_FEATURE_UDHCPC_ARPING( \
  4470. "\n -a,--arping Use arping to validate offered address" \
  4471. ) \
  4472. "\n -O,--request-option OPT Request DHCP option OPT (cumulative)" \
  4473. "\n -o,--no-default-options Don't request any options (unless -O is given)" \
  4474. "\n -x OPT:VAL Include option OPT in sent packets (cumulative)" \
  4475. "\n -F,--fqdn NAME Ask server to update DNS mapping for NAME" \
  4476. "\n -H,-h,--hostname NAME Send NAME as client hostname (default none)" \
  4477. "\n -V,--vendorclass VENDOR Vendor identifier (default 'udhcp VERSION')" \
  4478. "\n -c,--clientid CLIENTID Client identifier (default own MAC)" \
  4479. "\n -C,--clientid-none Don't send client identifier" \
  4480. ) \
  4481. IF_NOT_LONG_OPTS( \
  4482. "\n -i IFACE Interface to use (default eth0)" \
  4483. "\n -p FILE Create pidfile" \
  4484. "\n -r IP IP address to request" \
  4485. "\n -s PROG Run PROG at DHCP events (default "CONFIG_UDHCPC_DEFAULT_SCRIPT")" \
  4486. "\n -t N Send up to N discover packets" \
  4487. "\n -T N Pause between packets (default 3 seconds)" \
  4488. "\n -A N Wait N seconds (default 20) after failure" \
  4489. "\n -x OPT:VAL Include option OPT in sent packets" \
  4490. "\n -O OPT Request DHCP option OPT (cumulative)" \
  4491. "\n -o Don't request any options (unless -O is given)" \
  4492. "\n -f Run in foreground" \
  4493. USE_FOR_MMU( \
  4494. "\n -b Background if lease is not obtained" \
  4495. ) \
  4496. "\n -S Log to syslog too" \
  4497. "\n -n Exit if lease is not obtained" \
  4498. "\n -q Exit after obtaining lease" \
  4499. "\n -R Release IP on exit" \
  4500. IF_FEATURE_UDHCP_PORT( \
  4501. "\n -P N Use port N (default 68)" \
  4502. ) \
  4503. IF_FEATURE_UDHCPC_ARPING( \
  4504. "\n -a Use arping to validate offered address" \
  4505. ) \
  4506. "\n -F NAME Ask server to update DNS mapping for NAME" \
  4507. "\n -H,-h NAME Send NAME as client hostname (default none)" \
  4508. "\n -V VENDOR Vendor identifier (default 'udhcp VERSION')" \
  4509. "\n -c CLIENTID Client identifier (default own MAC)" \
  4510. "\n -C Don't send client identifier" \
  4511. )
  4512. #define udhcpd_trivial_usage \
  4513. "[-fS]" IF_FEATURE_UDHCP_PORT(" [-P N]") " [configfile]" \
  4514. #define udhcpd_full_usage "\n\n" \
  4515. "DHCP server\n" \
  4516. "\n -f Run in foreground" \
  4517. "\n -S Log to syslog too" \
  4518. IF_FEATURE_UDHCP_PORT( \
  4519. "\n -P N Use port N (default 67)" \
  4520. )
  4521. #define umount_trivial_usage \
  4522. "[OPTIONS] FILESYSTEM|DIRECTORY"
  4523. #define umount_full_usage "\n\n" \
  4524. "Unmount file systems\n" \
  4525. "\nOptions:" \
  4526. IF_FEATURE_UMOUNT_ALL( \
  4527. "\n -a Unmount all file systems" IF_FEATURE_MTAB_SUPPORT(" in /etc/mtab") \
  4528. ) \
  4529. IF_FEATURE_MTAB_SUPPORT( \
  4530. "\n -n Don't erase /etc/mtab entries" \
  4531. ) \
  4532. "\n -r Try to remount devices as read-only if mount is busy" \
  4533. "\n -l Lazy umount (detach filesystem)" \
  4534. "\n -f Force umount (i.e., unreachable NFS server)" \
  4535. IF_FEATURE_MOUNT_LOOP( \
  4536. "\n -d Free loop device if it has been used" \
  4537. )
  4538. #define umount_example_usage \
  4539. "$ umount /dev/hdc1\n"
  4540. #define uname_trivial_usage \
  4541. "[-amnrspv]"
  4542. #define uname_full_usage "\n\n" \
  4543. "Print system information\n" \
  4544. "\nOptions:" \
  4545. "\n -a Print all" \
  4546. "\n -m The machine (hardware) type" \
  4547. "\n -n Hostname" \
  4548. "\n -r OS release" \
  4549. "\n -s OS name (default)" \
  4550. "\n -p Processor type" \
  4551. "\n -v OS version" \
  4552. #define uname_example_usage \
  4553. "$ uname -a\n" \
  4554. "Linux debian 2.4.23 #2 Tue Dec 23 17:09:10 MST 2003 i686 GNU/Linux\n"
  4555. #define uncompress_trivial_usage \
  4556. "[-cf] [FILE]..."
  4557. #define uncompress_full_usage "\n\n" \
  4558. "Uncompress .Z file[s]\n" \
  4559. "\nOptions:" \
  4560. "\n -c Extract to stdout" \
  4561. "\n -f Overwrite an existing file" \
  4562. #define unexpand_trivial_usage \
  4563. "[-fa][-t N] [FILE]..."
  4564. #define unexpand_full_usage "\n\n" \
  4565. "Convert spaces to tabs, writing to stdout\n" \
  4566. "\nOptions:" \
  4567. IF_FEATURE_UNEXPAND_LONG_OPTIONS( \
  4568. "\n -a,--all Convert all blanks" \
  4569. "\n -f,--first-only Convert only leading blanks" \
  4570. "\n -t,--tabs=N Tabstops every N chars" \
  4571. ) \
  4572. IF_NOT_FEATURE_UNEXPAND_LONG_OPTIONS( \
  4573. "\n -a Convert all blanks" \
  4574. "\n -f Convert only leading blanks" \
  4575. "\n -t N Tabstops every N chars" \
  4576. )
  4577. #define uniq_trivial_usage \
  4578. "[-cdu][-f,s,w N] [INPUT [OUTPUT]]"
  4579. #define uniq_full_usage "\n\n" \
  4580. "Discard duplicate lines\n" \
  4581. "\nOptions:" \
  4582. "\n -c Prefix lines by the number of occurrences" \
  4583. "\n -d Only print duplicate lines" \
  4584. "\n -u Only print unique lines" \
  4585. "\n -f N Skip first N fields" \
  4586. "\n -s N Skip first N chars (after any skipped fields)" \
  4587. "\n -w N Compare N characters in line" \
  4588. #define uniq_example_usage \
  4589. "$ echo -e \"a\\na\\nb\\nc\\nc\\na\" | sort | uniq\n" \
  4590. "a\n" \
  4591. "b\n" \
  4592. "c\n"
  4593. #define unzip_trivial_usage \
  4594. "[-opts[modifiers]] FILE[.zip] [LIST] [-x XLIST] [-d DIR]"
  4595. #define unzip_full_usage "\n\n" \
  4596. "Extract files from ZIP archives\n" \
  4597. "\nOptions:" \
  4598. "\n -l List archive contents (with -q for short form)" \
  4599. "\n -n Never overwrite existing files (default)" \
  4600. "\n -o Overwrite files without prompting" \
  4601. "\n -p Send output to stdout" \
  4602. "\n -q Quiet" \
  4603. "\n -x XLST Exclude these files" \
  4604. "\n -d DIR Extract files into DIR" \
  4605. #define uptime_trivial_usage \
  4606. ""
  4607. #define uptime_full_usage "\n\n" \
  4608. "Display the time since the last boot"
  4609. #define uptime_example_usage \
  4610. "$ uptime\n" \
  4611. " 1:55pm up 2:30, load average: 0.09, 0.04, 0.00\n"
  4612. #define usleep_trivial_usage \
  4613. "N"
  4614. #define usleep_full_usage "\n\n" \
  4615. "Pause for N microseconds"
  4616. #define usleep_example_usage \
  4617. "$ usleep 1000000\n" \
  4618. "[pauses for 1 second]\n"
  4619. #define uudecode_trivial_usage \
  4620. "[-o OUTFILE] [INFILE]"
  4621. #define uudecode_full_usage "\n\n" \
  4622. "Uudecode a file\n" \
  4623. "Finds outfile name in uuencoded source unless -o is given"
  4624. #define uudecode_example_usage \
  4625. "$ uudecode -o busybox busybox.uu\n" \
  4626. "$ ls -l busybox\n" \
  4627. "-rwxr-xr-x 1 ams ams 245264 Jun 7 21:35 busybox\n"
  4628. #define uuencode_trivial_usage \
  4629. "[-m] [INFILE] STORED_FILENAME"
  4630. #define uuencode_full_usage "\n\n" \
  4631. "Uuencode a file to stdout\n" \
  4632. "\nOptions:" \
  4633. "\n -m Use base64 encoding per RFC1521" \
  4634. #define uuencode_example_usage \
  4635. "$ uuencode busybox busybox\n" \
  4636. "begin 755 busybox\n" \
  4637. "<encoded file snipped>\n" \
  4638. "$ uudecode busybox busybox > busybox.uu\n" \
  4639. "$\n"
  4640. #define vconfig_trivial_usage \
  4641. "COMMAND [OPTIONS]"
  4642. #define vconfig_full_usage "\n\n" \
  4643. "Create and remove virtual ethernet devices\n" \
  4644. "\nOptions:" \
  4645. "\n add [interface-name] [vlan_id]" \
  4646. "\n rem [vlan-name]" \
  4647. "\n set_flag [interface-name] [flag-num] [0 | 1]" \
  4648. "\n set_egress_map [vlan-name] [skb_priority] [vlan_qos]" \
  4649. "\n set_ingress_map [vlan-name] [skb_priority] [vlan_qos]" \
  4650. "\n set_name_type [name-type]" \
  4651. #define vi_trivial_usage \
  4652. "[OPTIONS] [FILE]..."
  4653. #define vi_full_usage "\n\n" \
  4654. "Edit FILE\n" \
  4655. "\nOptions:" \
  4656. IF_FEATURE_VI_COLON( \
  4657. "\n -c Initial command to run ($EXINIT also available)") \
  4658. IF_FEATURE_VI_READONLY( \
  4659. "\n -R Read-only") \
  4660. "\n -H Short help regarding available features" \
  4661. #define vlock_trivial_usage \
  4662. "[OPTIONS]"
  4663. #define vlock_full_usage "\n\n" \
  4664. "Lock a virtual terminal. A password is required to unlock.\n" \
  4665. "\nOptions:" \
  4666. "\n -a Lock all VTs" \
  4667. #define volname_trivial_usage \
  4668. "[DEVICE]"
  4669. #define volname_full_usage "\n\n" \
  4670. "Show CD volume name of the DEVICE (default /dev/cdrom)"
  4671. #define wall_trivial_usage \
  4672. "[FILE]"
  4673. #define wall_full_usage "\n\n" \
  4674. "Write content of FILE or stdin to all logged-in users"
  4675. #define wall_sample_usage \
  4676. "echo foo | wall\n" \
  4677. "wall ./mymessage"
  4678. #define watch_trivial_usage \
  4679. "[-n SEC] [-t] PROG ARGS"
  4680. #define watch_full_usage "\n\n" \
  4681. "Run PROG periodically\n" \
  4682. "\nOptions:" \
  4683. "\n -n Loop period in seconds (default 2)" \
  4684. "\n -t Don't print header" \
  4685. #define watch_example_usage \
  4686. "$ watch date\n" \
  4687. "Mon Dec 17 10:31:40 GMT 2000\n" \
  4688. "Mon Dec 17 10:31:42 GMT 2000\n" \
  4689. "Mon Dec 17 10:31:44 GMT 2000"
  4690. #define watchdog_trivial_usage \
  4691. "[-t N[ms]] [-T N[ms]] [-F] DEV"
  4692. #define watchdog_full_usage "\n\n" \
  4693. "Periodically write to watchdog device DEV\n" \
  4694. "\nOptions:" \
  4695. "\n -T N Reboot after N seconds if not reset (default 60)" \
  4696. "\n -t N Reset every N seconds (default 30)" \
  4697. "\n -F Run in foreground" \
  4698. "\n" \
  4699. "\nUse 500ms to specify period in milliseconds" \
  4700. #define wc_trivial_usage \
  4701. "[OPTIONS] [FILE]..."
  4702. #define wc_full_usage "\n\n" \
  4703. "Print line, word, and byte counts for each FILE (or stdin),\n" \
  4704. "and a total line if more than one FILE is specified\n" \
  4705. "\nOptions:" \
  4706. "\n -c Print the byte counts" \
  4707. "\n -l Print the newline counts" \
  4708. "\n -L Print the length of the longest line" \
  4709. "\n -w Print the word counts" \
  4710. #define wc_example_usage \
  4711. "$ wc /etc/passwd\n" \
  4712. " 31 46 1365 /etc/passwd\n"
  4713. #define wget_trivial_usage \
  4714. IF_FEATURE_WGET_LONG_OPTIONS( \
  4715. "[-c|--continue] [-s|--spider] [-q|--quiet] [-O|--output-document FILE]\n" \
  4716. " [--header 'header: value'] [-Y|--proxy on/off] [-P DIR]\n" \
  4717. " [--no-check-certificate] [-U|--user-agent AGENT] URL" \
  4718. ) \
  4719. IF_NOT_FEATURE_WGET_LONG_OPTIONS( \
  4720. "[-csq] [-O FILE] [-Y on/off] [-P DIR] [-U AGENT] URL" \
  4721. )
  4722. #define wget_full_usage "\n\n" \
  4723. "Retrieve files via HTTP or FTP\n" \
  4724. "\nOptions:" \
  4725. "\n -s Spider mode - only check file existence" \
  4726. "\n -c Continue retrieval of aborted transfer" \
  4727. "\n -q Quiet" \
  4728. "\n -P Set directory prefix to DIR" \
  4729. "\n -O FILE Save to FILE ('-' for stdout)" \
  4730. "\n -U STR Use STR for User-Agent header" \
  4731. "\n -Y Use proxy ('on' or 'off')" \
  4732. #define which_trivial_usage \
  4733. "[COMMAND]..."
  4734. #define which_full_usage "\n\n" \
  4735. "Locate a COMMAND"
  4736. #define which_example_usage \
  4737. "$ which login\n" \
  4738. "/bin/login\n"
  4739. #define who_trivial_usage \
  4740. "[-a]"
  4741. #define who_full_usage "\n\n" \
  4742. "Show who is logged on\n" \
  4743. "\nOptions:" \
  4744. "\n -a show all" \
  4745. #define whoami_trivial_usage \
  4746. ""
  4747. #define whoami_full_usage "\n\n" \
  4748. "Print the user name associated with the current effective user id"
  4749. #define xargs_trivial_usage \
  4750. "[OPTIONS] [PROG ARGS]"
  4751. #define xargs_full_usage "\n\n" \
  4752. "Run PROG on every item given by stdin\n" \
  4753. "\nOptions:" \
  4754. IF_FEATURE_XARGS_SUPPORT_CONFIRMATION( \
  4755. "\n -p Ask user whether to run each command") \
  4756. "\n -r Don't run command if input is empty" \
  4757. IF_FEATURE_XARGS_SUPPORT_ZERO_TERM( \
  4758. "\n -0 Input is separated by NUL characters") \
  4759. "\n -t Print the command on stderr before execution" \
  4760. "\n -e[STR] STR stops input processing" \
  4761. "\n -n N Pass no more than N args to PROG" \
  4762. "\n -s N Pass command line of no more than N bytes" \
  4763. IF_FEATURE_XARGS_SUPPORT_TERMOPT( \
  4764. "\n -x Exit if size is exceeded") \
  4765. #define xargs_example_usage \
  4766. "$ ls | xargs gzip\n" \
  4767. "$ find . -name '*.c' -print | xargs rm\n"
  4768. #define yes_trivial_usage \
  4769. "[OPTIONS] [STRING]"
  4770. #define yes_full_usage "\n\n" \
  4771. "Repeatedly output a line with STRING, or 'y'"
  4772. #define zcat_trivial_usage \
  4773. "FILE"
  4774. #define zcat_full_usage "\n\n" \
  4775. "Uncompress to stdout"
  4776. #define zcip_trivial_usage \
  4777. "[OPTIONS] IFACE SCRIPT"
  4778. #define zcip_full_usage "\n\n" \
  4779. "Manage a ZeroConf IPv4 link-local address\n" \
  4780. "\nOptions:" \
  4781. "\n -f Run in foreground" \
  4782. "\n -q Quit after obtaining address" \
  4783. "\n -r 169.254.x.x Request this address first" \
  4784. "\n -v Verbose" \
  4785. "\n" \
  4786. "\nWith no -q, runs continuously monitoring for ARP conflicts," \
  4787. "\nexits only on I/O errors (link down etc)" \
  4788. #endif