home *** CD-ROM | disk | FTP | other *** search
/ The Datafile PD-CD 3 / PDCD_3.iso / utilities / utilsf / gnuinfo < prev    next >
ArcFS Archive  |  1995-09-23  |  323.7 KB

open in: MacOS 8.1     |     Win98     |     DOS

browse contents    |     view JSON data     |     view as text


This file was processed as: ArcFS Archive (archive/arcFS).

ConfidenceProgramDetectionMatch TypeSupport
100% dexvert ArcFS Archive (archive/arcFS) magic Supported
100% file RISC OS archive (ArcFS format) default
99% file data default
100% TrID Acorn ArcFS Archive default
100% gt2 Kopftext: 'Archive' default (weak)
100% detectItEasy Archive: ArcFS default



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 41 72 63 68 69 76 65 00 | 64 02 00 00 54 03 00 00 |Archive.|d...T...|
|00000010| 28 00 00 00 64 00 00 00 | 00 00 00 00 00 00 00 00 |(...d...|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000050| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000060| 82 65 74 63 00 00 00 00 | 00 00 00 00 ff ff ff ff |.etc....|........|
|00000070| 46 ff ff ff 09 83 d5 55 | 33 00 00 00 ff ff ff ff |F......U|3.......|
|00000080| 8c 01 00 80 82 69 6e 66 | 6f 00 00 00 df 87 00 00 |.....inf|o.......|
|00000090| ff ff ff ff 46 ff ff ff | 3b 83 d5 55 00 00 00 00 |....F...|;..U....|
|000000a0| ff ff ff ff 44 01 00 80 | 82 44 49 52 00 00 00 00 |....D...|.DIR....|
|000000b0| 00 00 00 00 38 05 00 00 | 45 e4 ff ff 8f 15 41 ae |....8...|E.....A.|
|000000c0| 03 00 69 fe 38 05 00 00 | 24 00 00 00 82 45 64 00 |..i.8...|$....Ed.|
|000000d0| 00 00 00 00 00 00 00 00 | 8f 5d 00 00 45 ff ff ff |........|.]..E...|
|000000e0| fc ea f9 94 03 00 78 a8 | 8f 5d 00 00 80 05 00 00 |......x.|.]......|
|000000f0| 82 67 64 62 6d 00 00 00 | 00 00 00 00 a2 5e 00 00 |.gdbm...|.....^..|
|00000100| 45 fd ff ff 74 19 84 58 | 33 00 01 c3 a2 5e 00 00 |E...t..X|3....^..|
|00000110| 33 63 00 00 82 47 4e 55 | 73 74 64 73 00 00 00 00 |3c...GNU|stds....|
|00000120| ee 04 01 00 45 ff ff ff | 15 fc 40 ae 33 00 41 35 |....E...|..@.3.A5|
|00000130| ee 04 01 00 f9 c1 00 00 | 82 49 4e 46 4f 00 00 00 |........|.INFO...|
|00000140| 00 00 00 00 02 6b 00 00 | 45 e4 ff ff f4 e5 0e a0 |.....k..|E.......|
|00000150| 03 00 17 fd 02 6b 00 00 | 0b c7 01 00 82 52 45 47 |.....k..|.....REG|
|00000160| 45 58 00 00 00 00 00 00 | fe 5a 00 00 45 e4 ff ff |EX......|.Z..E...|
|00000170| b0 df cc 94 03 00 f6 fd | fe 5a 00 00 31 32 02 00 |........|.Z..12..|
|00000180| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000190| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000001a0| 00 00 00 00 82 74 65 72 | 6d 63 61 70 00 87 00 00 |.....ter|mcap....|
|000001b0| 24 01 00 00 45 ff ff ff | 7f 5b 07 b0 03 00 86 f0 |$...E...|.[......|
|000001c0| 24 01 00 00 53 8d 02 00 | 00 61 62 e5 00 00 00 00 |$...S...|.ab.....|
|000001d0| df 87 00 00 14 19 81 84 | 48 06 00 00 82 21 52 75 |........|H....!Ru|
|000001e0| 6e 49 6d 61 67 65 00 00 | 5b 04 00 00 82 67 6e 75 |nImage..|[....gnu|
|000001f0| 69 6e 66 6f 00 00 00 00 | 77 01 00 00 45 eb ff ff |info....|w...E...|
|00000200| 01 75 c9 b7 33 00 46 22 | 77 01 00 00 9b 8e 02 00 |.u..3.F"|w.......|
|00000210| 82 6d 61 6b 65 69 6e 66 | 6f 00 00 00 9f ef 00 00 |.makeinf|o.......|
|00000220| 45 f8 ff ff 9e 63 91 9d | 03 00 5b e8 9f ef 00 00 |E....c..|..[.....|
|00000230| 36 90 02 00 82 52 65 61 | 64 4d 65 31 73 74 00 00 |6....Rea|dMe1st..|
|00000240| 6b 06 00 00 45 ff ff ff | 62 ca ca b7 33 00 29 c1 |k...E...|b...3.).|
|00000250| 6b 06 00 00 f9 7f 03 00 | 82 75 6e 69 78 63 61 74 |k.......|.unixcat|
|00000260| 00 00 00 00 ef 47 00 00 | 45 f8 ff ff be 82 92 a0 |.....G..|E.......|
|00000270| 03 00 dd 35 ef 47 00 00 | 88 86 03 00 82 78 69 6e |...5.G..|.....xin|
|00000280| 66 6f 00 00 00 00 00 00 | bf 3c 01 00 45 f8 ff ff |fo......|.<..E...|
|00000290| 46 67 e3 9d 03 00 f8 99 | bf 3c 01 00 9b ce 03 00 |Fg......|.<......|
|000002a0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000002b0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000002c0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000002d0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000002e0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000002f0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000300| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000310| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000320| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000330| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000340| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000350| 00 00 00 00 46 69 6c 65 | 44 61 74 61 82 44 49 52 |....File|Data.DIR|
|00000360| 00 00 00 00 00 00 00 00 | 38 05 00 00 45 e4 ff ff |........|8...E...|
|00000370| 8f 15 41 ae 03 00 69 fe | 2d 2a 2d 20 54 65 78 74 |..A...i.|-*- Text|
|00000380| 20 2d 2a 2d 0a 54 68 69 | 73 20 69 73 20 74 68 65 | -*-.Thi|s is the|
|00000390| 20 66 69 6c 65 20 2e 2e | 2e 2f 69 6e 66 6f 2f 64 | file ..|./info/d|
|000003a0| 69 72 2c 20 77 68 69 63 | 68 20 63 6f 6e 74 61 69 |ir, whic|h contai|
|000003b0| 6e 73 20 74 68 65 20 74 | 6f 70 6d 6f 73 74 20 6e |ns the t|opmost n|
|000003c0| 6f 64 65 20 6f 66 20 74 | 68 65 0a 49 6e 66 6f 20 |ode of t|he.Info |
|000003d0| 68 69 65 72 61 72 63 68 | 79 2e 20 20 54 68 65 20 |hierarch|y. The |
|000003e0| 66 69 72 73 74 20 74 69 | 6d 65 20 79 6f 75 20 69 |first ti|me you i|
|000003f0| 6e 76 6f 6b 65 20 49 6e | 66 6f 20 79 6f 75 20 73 |nvoke In|fo you s|
|00000400| 74 61 72 74 20 6f 66 66 | 0a 6c 6f 6f 6b 69 6e 67 |tart off|.looking|
|00000410| 20 61 74 20 74 68 61 74 | 20 6e 6f 64 65 2c 20 77 | at that| node, w|
|00000420| 68 69 63 68 20 69 73 20 | 28 64 69 72 29 54 6f 70 |hich is |(dir)Top|
|00000430| 2e 0a 1f 0a 46 69 6c 65 | 3a 20 64 69 72 09 4e 6f |....File|: dir.No|
|00000440| 64 65 3a 20 54 6f 70 09 | 54 68 69 73 20 69 73 20 |de: Top.|This is |
|00000450| 74 68 65 20 74 6f 70 20 | 6f 66 20 74 68 65 20 49 |the top |of the I|
|00000460| 4e 46 4f 20 74 72 65 65 | 0a 20 20 54 68 69 73 20 |NFO tree|. This |
|00000470| 28 74 68 65 20 44 69 72 | 65 63 74 6f 72 79 20 6e |(the Dir|ectory n|
|00000480| 6f 64 65 29 20 67 69 76 | 65 73 20 61 20 6d 65 6e |ode) giv|es a men|
|00000490| 75 20 6f 66 20 6d 61 6a | 6f 72 20 74 6f 70 69 63 |u of maj|or topic|
|000004a0| 73 2e 20 0a 20 20 54 79 | 70 69 6e 67 20 22 64 22 |s. . Ty|ping "d"|
|000004b0| 20 72 65 74 75 72 6e 73 | 20 68 65 72 65 2c 20 22 | returns| here, "|
|000004c0| 71 22 20 65 78 69 74 73 | 2c 20 22 3f 22 20 6c 69 |q" exits|, "?" li|
|000004d0| 73 74 73 20 61 6c 6c 20 | 49 4e 46 4f 20 63 6f 6d |sts all |INFO com|
|000004e0| 6d 61 6e 64 73 2c 20 22 | 68 22 20 0a 20 20 67 69 |mands, "|h" . gi|
|000004f0| 76 65 73 20 61 20 70 72 | 69 6d 65 72 20 66 6f 72 |ves a pr|imer for|
|00000500| 20 66 69 72 73 74 2d 74 | 69 6d 65 72 73 2c 20 22 | first-t|imers, "|
|00000510| 6d 54 65 78 69 6e 66 6f | 3c 52 65 74 75 72 6e 3e |mTexinfo|<Return>|
|00000520| 22 20 76 69 73 69 74 73 | 20 54 65 78 69 6e 66 6f |" visits| Texinfo|
|00000530| 20 74 6f 70 69 63 2c 0a | 20 20 65 74 63 2e 0a 20 | topic,.| etc.. |
|00000540| 20 2d 2d 2d 20 50 4c 45 | 41 53 45 20 41 44 44 20 | --- PLE|ASE ADD |
|00000550| 44 4f 43 55 4d 45 4e 54 | 41 54 49 4f 4e 20 54 4f |DOCUMENT|ATION TO|
|00000560| 20 54 48 49 53 20 54 52 | 45 45 2e 20 28 53 65 65 | THIS TR|EE. (See|
|00000570| 20 49 4e 46 4f 20 74 6f | 70 69 63 20 66 69 72 73 | INFO to|pic firs|
|00000580| 74 2e 29 20 2d 2d 2d 0a | 0a 2a 20 4d 65 6e 75 3a |t.) ---.|.* Menu:|
|00000590| 20 54 68 65 20 6c 69 73 | 74 20 6f 66 20 6d 61 6a | The lis|t of maj|
|000005a0| 6f 72 20 74 6f 70 69 63 | 73 20 62 65 67 69 6e 73 |or topic|s begins|
|000005b0| 20 6f 6e 20 74 68 65 20 | 6e 65 78 74 20 6c 69 6e | on the |next lin|
|000005c0| 65 2e 0a 0a 2a 20 49 6e | 66 6f 3a 3a 09 44 6f 63 |e...* In|fo::.Doc|
|000005d0| 75 6d 65 6e 74 61 74 69 | 6f 6e 20 62 72 6f 77 73 |umentati|on brows|
|000005e0| 69 6e 67 20 73 79 73 74 | 65 6d 2e 0a 2a 20 45 6d |ing syst|em..* Em|
|000005f0| 61 63 73 3a 3a 09 54 68 | 65 20 65 78 74 65 6e 73 |acs::.Th|e extens|
|00000600| 69 62 6c 65 20 73 65 6c | 66 2d 64 6f 63 75 6d 65 |ible sel|f-docume|
|00000610| 6e 74 69 6e 67 20 74 65 | 78 74 20 65 64 69 74 6f |nting te|xt edito|
|00000620| 72 2e 20 28 4e 50 29 0a | 2a 20 45 6c 69 73 70 3a |r. (NP).|* Elisp:|
|00000630| 3a 09 54 68 65 20 6c 61 | 6e 67 75 61 67 65 20 66 |:.The la|nguage f|
|00000640| 6f 72 20 70 72 6f 67 72 | 61 6d 6d 69 6e 67 20 45 |or progr|amming E|
|00000650| 6d 61 63 73 2e 20 28 4e | 50 29 0a 2a 20 50 65 72 |macs. (N|P).* Per|
|00000660| 6c 3a 3a 09 47 6f 6f 64 | 20 61 6c 6c 2d 70 75 72 |l::.Good| all-pur|
|00000670| 70 6f 73 65 20 69 6e 74 | 65 72 70 72 65 74 65 64 |pose int|erpreted|
|00000680| 2f 63 6f 6d 70 69 6c 65 | 64 20 6c 61 6e 67 75 61 |/compile|d langua|
|00000690| 67 65 2e 20 28 4e 50 29 | 0a 2a 20 54 65 78 69 6e |ge. (NP)|.* Texin|
|000006a0| 66 6f 3a 20 28 74 65 78 | 69 29 2e 0a 09 09 57 69 |fo: (tex|i)....Wi|
|000006b0| 74 68 20 6f 6e 65 20 73 | 6f 75 72 63 65 20 66 69 |th one s|ource fi|
|000006c0| 6c 65 2c 20 6d 61 6b 65 | 20 65 69 74 68 65 72 20 |le, make| either |
|000006d0| 61 20 70 72 69 6e 74 65 | 64 20 6d 61 6e 75 61 6c |a printe|d manual|
|000006e0| 0a 09 09 28 74 68 72 6f | 75 67 68 20 54 65 58 29 |...(thro|ugh TeX)|
|000006f0| 20 6f 72 20 61 6e 20 49 | 6e 66 6f 20 66 69 6c 65 | or an I|nfo file|
|00000700| 20 28 74 68 72 6f 75 67 | 68 20 74 65 78 69 6e 66 | (throug|h texinf|
|00000710| 6f 29 2e 0a 2a 20 45 64 | 3a 3a 09 09 54 68 65 20 |o)..* Ed|::..The |
|00000720| 73 6d 61 6c 6c 2c 20 62 | 75 74 20 6c 6f 76 65 61 |small, b|ut lovea|
|00000730| 62 6c 65 20 65 64 69 74 | 6f 72 2e 0a 2a 20 54 65 |ble edit|or..* Te|
|00000740| 72 6d 63 61 70 3a 3a 09 | 54 68 65 20 74 65 72 6d |rmcap::.|The term|
|00000750| 63 61 70 20 6c 69 62 72 | 61 72 79 2c 20 77 68 69 |cap libr|ary, whi|
|00000760| 63 68 20 65 6e 61 62 6c | 65 73 20 61 70 70 6c 69 |ch enabl|es appli|
|00000770| 63 61 74 69 6f 6e 20 70 | 72 6f 67 72 61 6d 73 0a |cation p|rograms.|
|00000780| 09 09 74 6f 20 68 61 6e | 64 6c 65 20 61 6c 6c 20 |..to han|dle all |
|00000790| 74 79 70 65 73 20 6f 66 | 20 63 68 61 72 61 63 74 |types of| charact|
|000007a0| 65 72 2d 64 69 73 70 6c | 61 79 20 74 65 72 6d 69 |er-displ|ay termi|
|000007b0| 6e 61 6c 73 2e 0a 2a 20 | 52 65 67 65 78 3a 3a 09 |nals..* |Regex::.|
|000007c0| 54 68 65 20 47 4e 55 20 | 72 65 67 75 6c 61 72 20 |The GNU |regular |
|000007d0| 65 78 70 72 65 73 73 69 | 6f 6e 20 6c 69 62 72 61 |expressi|on libra|
|000007e0| 72 79 2e 0a 2a 20 47 64 | 62 6d 3a 3a 09 54 68 65 |ry..* Gd|bm::.The|
|000007f0| 20 47 4e 55 20 64 61 74 | 61 62 61 73 65 20 6d 61 | GNU dat|abase ma|
|00000800| 6e 61 67 65 72 20 66 6f | 72 20 65 78 74 65 6e 64 |nager fo|r extend|
|00000810| 69 62 6c 65 20 68 61 73 | 68 65 64 20 64 61 74 61 |ible has|hed data|
|00000820| 62 61 73 65 73 2e 0a 2a | 20 44 69 66 66 3a 3a 09 |bases..*| Diff::.|
|00000830| 47 4e 55 27 73 20 66 61 | 73 74 65 72 20 64 69 66 |GNU's fa|ster dif|
|00000840| 66 20 28 2b 6f 74 68 65 | 72 20 66 6c 61 76 6f 75 |f (+othe|r flavou|
|00000850| 72 73 29 2e 0a 2a 20 53 | 6d 61 6c 6c 74 61 6c 6b |rs)..* S|malltalk|
|00000860| 3a 3a 09 47 4e 55 20 53 | 6d 61 6c 6c 74 61 6c 6b |::.GNU S|malltalk|
|00000870| 0a 2a 20 46 6c 65 78 3a | 3a 09 47 4e 55 20 66 6c |.* Flex:|:.GNU fl|
|00000880| 65 78 20 32 2e 33 0a 2a | 20 47 4e 55 73 74 64 73 |ex 2.3.*| GNUstds|
|00000890| 3a 3a 09 47 4e 55 20 63 | 6f 64 69 6e 67 20 73 74 |::.GNU c|oding st|
|000008a0| 61 6e 64 61 72 64 73 20 | 66 6f 72 20 43 0a 09 09 |andards |for C...|
|000008b0| 46 69 6c 65 44 61 74 61 | 82 45 64 00 00 00 00 00 |FileData|.Ed.....|
|000008c0| 00 00 00 00 8f 5d 00 00 | 46 fd ff ff a2 83 d5 55 |.....]..|F......U|
|000008d0| 03 00 78 a8 54 68 69 73 | 20 69 73 20 49 6e 66 6f |..x.This| is Info|
|000008e0| 20 66 69 6c 65 20 65 64 | 2e 69 6e 66 6f 2c 20 70 | file ed|.info, p|
|000008f0| 72 6f 64 75 63 65 64 20 | 62 79 20 4d 61 6b 65 69 |roduced |by Makei|
|00000900| 6e 66 6f 2d 31 2e 35 35 | 20 66 72 6f 6d 20 74 68 |nfo-1.55| from th|
|00000910| 65 20 69 6e 70 75 74 0a | 66 69 6c 65 20 65 64 2e |e input.|file ed.|
|00000920| 74 65 78 69 6e 66 6f 2e | 0a 0a 20 20 20 54 68 69 |texinfo.|.. Thi|
|00000930| 73 20 66 69 6c 65 20 64 | 6f 63 75 6d 65 6e 74 73 |s file d|ocuments|
|00000940| 20 74 68 65 20 60 65 64 | 27 20 63 6f 6d 6d 61 6e | the `ed|' comman|
|00000950| 64 2c 20 77 68 69 63 68 | 20 68 61 73 20 74 68 65 |d, which| has the|
|00000960| 20 70 75 72 70 6f 73 65 | 20 6f 66 0a 65 64 69 74 | purpose| of.edit|
|00000970| 69 6e 67 20 74 65 78 74 | 20 66 69 6c 65 73 2e 0a |ing text| files..|
|00000980| 0a 20 20 20 43 6f 70 79 | 72 69 67 68 74 20 28 43 |. Copy|right (C|
|00000990| 29 20 31 39 39 33 20 62 | 79 20 74 68 65 20 46 72 |) 1993 b|y the Fr|
|000009a0| 65 65 20 53 6f 66 74 77 | 61 72 65 20 46 6f 75 6e |ee Softw|are Foun|
|000009b0| 64 61 74 69 6f 6e 2c 20 | 49 6e 63 2e 0a 0a 20 20 |dation, |Inc... |
|000009c0| 20 50 65 72 6d 69 73 73 | 69 6f 6e 20 69 73 20 67 | Permiss|ion is g|
|000009d0| 72 61 6e 74 65 64 20 74 | 6f 20 6d 61 6b 65 20 61 |ranted t|o make a|
|000009e0| 6e 64 20 64 69 73 74 72 | 69 62 75 74 65 20 76 65 |nd distr|ibute ve|
|000009f0| 72 62 61 74 69 6d 20 63 | 6f 70 69 65 73 20 6f 66 |rbatim c|opies of|
|00000a00| 20 74 68 69 73 0a 6d 61 | 6e 75 61 6c 20 70 72 6f | this.ma|nual pro|
|00000a10| 76 69 64 65 64 20 74 68 | 65 20 63 6f 70 79 72 69 |vided th|e copyri|
|00000a20| 67 68 74 20 6e 6f 74 69 | 63 65 20 61 6e 64 20 74 |ght noti|ce and t|
|00000a30| 68 69 73 20 70 65 72 6d | 69 73 73 69 6f 6e 20 6e |his perm|ission n|
|00000a40| 6f 74 69 63 65 20 61 72 | 65 0a 70 72 65 73 65 72 |otice ar|e.preser|
|00000a50| 76 65 64 20 6f 6e 20 61 | 6c 6c 20 63 6f 70 69 65 |ved on a|ll copie|
|00000a60| 73 2e 0a 0a 20 20 20 50 | 65 72 6d 69 73 73 69 6f |s... P|ermissio|
|00000a70| 6e 20 69 73 20 67 72 61 | 6e 74 65 64 20 74 6f 20 |n is gra|nted to |
|00000a80| 63 6f 70 79 20 61 6e 64 | 20 64 69 73 74 72 69 62 |copy and| distrib|
|00000a90| 75 74 65 20 6d 6f 64 69 | 66 69 65 64 20 76 65 72 |ute modi|fied ver|
|00000aa0| 73 69 6f 6e 73 20 6f 66 | 0a 74 68 69 73 20 6d 61 |sions of|.this ma|
|00000ab0| 6e 75 61 6c 20 75 6e 64 | 65 72 20 74 68 65 20 63 |nual und|er the c|
|00000ac0| 6f 6e 64 69 74 69 6f 6e | 73 20 66 6f 72 20 76 65 |ondition|s for ve|
|00000ad0| 72 62 61 74 69 6d 20 63 | 6f 70 79 69 6e 67 2c 20 |rbatim c|opying, |
|00000ae0| 70 72 6f 76 69 64 65 64 | 20 74 68 61 74 0a 74 68 |provided| that.th|
|00000af0| 65 20 65 6e 74 69 72 65 | 20 72 65 73 75 6c 74 69 |e entire| resulti|
|00000b00| 6e 67 20 64 65 72 69 76 | 65 64 20 77 6f 72 6b 20 |ng deriv|ed work |
|00000b10| 69 73 20 64 69 73 74 72 | 69 62 75 74 65 64 20 75 |is distr|ibuted u|
|00000b20| 6e 64 65 72 20 74 68 65 | 20 74 65 72 6d 73 20 6f |nder the| terms o|
|00000b30| 66 20 61 0a 70 65 72 6d | 69 73 73 69 6f 6e 20 6e |f a.perm|ission n|
|00000b40| 6f 74 69 63 65 20 69 64 | 65 6e 74 69 63 61 6c 20 |otice id|entical |
|00000b50| 74 6f 20 74 68 69 73 20 | 6f 6e 65 2e 0a 0a 20 20 |to this |one... |
|00000b60| 20 50 65 72 6d 69 73 73 | 69 6f 6e 20 69 73 20 67 | Permiss|ion is g|
|00000b70| 72 61 6e 74 65 64 20 74 | 6f 20 63 6f 70 79 20 61 |ranted t|o copy a|
|00000b80| 6e 64 20 64 69 73 74 72 | 69 62 75 74 65 20 74 72 |nd distr|ibute tr|
|00000b90| 61 6e 73 6c 61 74 69 6f | 6e 73 20 6f 66 20 74 68 |anslatio|ns of th|
|00000ba0| 69 73 0a 6d 61 6e 75 61 | 6c 20 69 6e 74 6f 20 61 |is.manua|l into a|
|00000bb0| 6e 6f 74 68 65 72 20 6c | 61 6e 67 75 61 67 65 2c |nother l|anguage,|
|00000bc0| 20 75 6e 64 65 72 20 74 | 68 65 20 61 62 6f 76 65 | under t|he above|
|00000bd0| 20 63 6f 6e 64 69 74 69 | 6f 6e 73 20 66 6f 72 20 | conditi|ons for |
|00000be0| 6d 6f 64 69 66 69 65 64 | 0a 76 65 72 73 69 6f 6e |modified|.version|
|00000bf0| 73 2c 20 65 78 63 65 70 | 74 20 74 68 61 74 20 74 |s, excep|t that t|
|00000c00| 68 69 73 20 70 65 72 6d | 69 73 73 69 6f 6e 20 6e |his perm|ission n|
|00000c10| 6f 74 69 63 65 20 6d 61 | 79 20 62 65 20 73 74 61 |otice ma|y be sta|
|00000c20| 74 65 64 20 69 6e 20 61 | 0a 74 72 61 6e 73 6c 61 |ted in a|.transla|
|00000c30| 74 69 6f 6e 20 61 70 70 | 72 6f 76 65 64 20 62 79 |tion app|roved by|
|00000c40| 20 74 68 65 20 46 6f 75 | 6e 64 61 74 69 6f 6e 2e | the Fou|ndation.|
|00000c50| 0a 0a 1f 0a 46 69 6c 65 | 3a 20 65 64 2e 69 6e 66 |....File|: ed.inf|
|00000c60| 6f 2c 20 20 4e 6f 64 65 | 3a 20 54 6f 70 2c 20 20 |o, Node|: Top, |
|00000c70| 4e 65 78 74 3a 20 44 65 | 73 63 72 69 70 74 69 6f |Next: De|scriptio|
|00000c80| 6e 2c 20 20 50 72 65 76 | 3a 20 28 64 69 72 29 2c |n, Prev|: (dir),|
|00000c90| 20 20 55 70 3a 20 28 64 | 69 72 29 0a 0a 0a 0a 20 | Up: (d|ir).... |
|00000ca0| 20 20 54 68 69 73 20 66 | 69 6c 65 20 64 6f 63 75 | This f|ile docu|
|00000cb0| 6d 65 6e 74 73 20 74 68 | 65 20 60 65 64 27 20 63 |ments th|e `ed' c|
|00000cc0| 6f 6d 6d 61 6e 64 2c 20 | 61 73 20 6f 66 20 72 65 |ommand, |as of re|
|00000cd0| 6c 65 61 73 65 20 30 2e | 31 2e 20 20 59 6f 75 20 |lease 0.|1. You |
|00000ce0| 6d 61 79 0a 66 69 6e 64 | 20 69 6e 20 74 68 69 73 |may.find| in this|
|00000cf0| 20 64 6f 63 75 6d 65 6e | 74 3a 0a 0a 2a 20 4d 65 | documen|t:..* Me|
|00000d00| 6e 75 3a 0a 0a 2a 20 44 | 65 73 63 72 69 70 74 69 |nu:..* D|escripti|
|00000d10| 6f 6e 3a 3a 20 20 20 20 | 20 20 20 20 20 20 20 20 |on:: | |
|00000d20| 20 20 20 20 20 44 65 73 | 63 72 69 70 74 69 6f 6e | Des|cription|
|00000d30| 0a 2a 20 49 6e 76 6f 6b | 69 6e 67 3a 3a 20 20 20 |.* Invok|ing:: |
|00000d40| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00000d50| 20 49 6e 76 6f 6b 69 6e | 67 20 47 4e 55 20 60 65 | Invokin|g GNU `e|
|00000d60| 64 27 0a 2a 20 4c 69 6e | 65 20 61 64 64 72 65 73 |d'.* Lin|e addres|
|00000d70| 73 69 6e 67 3a 3a 20 20 | 20 20 20 20 20 20 20 20 |sing:: | |
|00000d80| 20 20 20 4c 69 6e 65 20 | 61 64 64 72 65 73 73 69 | Line |addressi|
|00000d90| 6e 67 0a 2a 20 52 65 67 | 75 6c 61 72 20 65 78 70 |ng.* Reg|ular exp|
|00000da0| 72 65 73 73 69 6f 6e 73 | 3a 3a 20 20 20 20 20 20 |ressions|:: |
|00000db0| 20 20 20 52 65 67 75 6c | 61 72 20 65 78 70 72 65 | Regul|ar expre|
|00000dc0| 73 73 69 6f 6e 73 0a 2a | 20 43 6f 6d 6d 61 6e 64 |ssions.*| Command|
|00000dd0| 73 3a 3a 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |s:: | |
|00000de0| 20 20 20 20 20 20 20 43 | 6f 6d 6d 61 6e 64 73 0a | C|ommands.|
|00000df0| 2a 20 4c 69 6d 69 74 61 | 74 69 6f 6e 73 3a 3a 20 |* Limita|tions:: |
|00000e00| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00000e10| 4c 69 6d 69 74 61 74 69 | 6f 6e 73 0a 2a 20 44 69 |Limitati|ons.* Di|
|00000e20| 61 67 6e 6f 73 74 69 63 | 73 3a 3a 20 20 20 20 20 |agnostic|s:: |
|00000e30| 20 20 20 20 20 20 20 20 | 20 20 20 20 44 69 61 67 | | Diag|
|00000e40| 6e 6f 73 74 69 63 73 0a | 0a 1f 0a 46 69 6c 65 3a |nostics.|...File:|
|00000e50| 20 65 64 2e 69 6e 66 6f | 2c 20 20 4e 6f 64 65 3a | ed.info|, Node:|
|00000e60| 20 44 65 73 63 72 69 70 | 74 69 6f 6e 2c 20 20 4e | Descrip|tion, N|
|00000e70| 65 78 74 3a 20 49 6e 76 | 6f 6b 69 6e 67 2c 20 20 |ext: Inv|oking, |
|00000e80| 50 72 65 76 3a 20 54 6f | 70 2c 20 20 55 70 3a 20 |Prev: To|p, Up: |
|00000e90| 54 6f 70 0a 0a 44 65 73 | 63 72 69 70 74 69 6f 6e |Top..Des|cription|
|00000ea0| 0a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 0a 0a 20 20 |.*******|****.. |
|00000eb0| 20 60 65 64 27 20 69 73 | 20 61 20 6c 69 6e 65 2d | `ed' is| a line-|
|00000ec0| 6f 72 69 65 6e 74 65 64 | 20 74 65 78 74 20 65 64 |oriented| text ed|
|00000ed0| 69 74 6f 72 2e 20 20 49 | 74 20 69 73 20 75 73 65 |itor. I|t is use|
|00000ee0| 64 20 74 6f 20 63 72 65 | 61 74 65 2c 20 64 69 73 |d to cre|ate, dis|
|00000ef0| 70 6c 61 79 2c 0a 6d 6f | 64 69 66 79 20 61 6e 64 |play,.mo|dify and|
|00000f00| 20 6f 74 68 65 72 77 69 | 73 65 20 6d 61 6e 69 70 | otherwi|se manip|
|00000f10| 75 6c 61 74 65 20 74 65 | 78 74 20 66 69 6c 65 73 |ulate te|xt files|
|00000f20| 2e 20 20 60 72 65 64 27 | 20 69 73 20 61 20 72 65 |. `red'| is a re|
|00000f30| 73 74 72 69 63 74 65 64 | 0a 60 65 64 27 3a 20 69 |stricted|.`ed': i|
|00000f40| 74 20 63 61 6e 20 6f 6e | 6c 79 20 65 64 69 74 20 |t can on|ly edit |
|00000f50| 66 69 6c 65 73 20 69 6e | 20 74 68 65 20 63 75 72 |files in| the cur|
|00000f60| 72 65 6e 74 20 64 69 72 | 65 63 74 6f 72 79 20 61 |rent dir|ectory a|
|00000f70| 6e 64 20 63 61 6e 6e 6f | 74 0a 65 78 65 63 75 74 |nd canno|t.execut|
|00000f80| 65 20 73 68 65 6c 6c 20 | 63 6f 6d 6d 61 6e 64 73 |e shell |commands|
|00000f90| 2e 0a 0a 20 20 20 52 65 | 6c 61 74 65 64 20 70 72 |... Re|lated pr|
|00000fa0| 6f 67 72 61 6d 73 20 6f | 72 20 72 6f 75 74 69 6e |ograms o|r routin|
|00000fb0| 65 73 20 61 72 65 20 60 | 76 69 20 28 31 29 27 2c |es are `|vi (1)',|
|00000fc0| 20 60 73 65 64 20 28 31 | 29 27 2c 20 60 72 65 67 | `sed (1|)', `reg|
|00000fd0| 65 78 20 28 33 29 27 2c | 0a 60 62 64 65 73 20 28 |ex (3)',|.`bdes (|
|00000fe0| 31 29 27 20 61 6e 64 20 | 60 73 68 20 28 31 29 27 |1)' and |`sh (1)'|
|00000ff0| 2e 20 20 52 65 6c 61 74 | 65 64 20 64 6f 63 75 6d |. Relat|ed docum|
|00001000| 65 6e 74 73 20 61 72 65 | 20 60 55 53 44 3a 31 32 |ents are| `USD:12|
|00001010| 2d 31 33 27 20 61 6e 64 | 3a 0a 0a 20 20 20 20 20 |-13' and|:.. |
|00001020| 42 2e 20 57 2e 20 4b 65 | 72 6e 69 67 68 61 6e 20 |B. W. Ke|rnighan |
|00001030| 61 6e 64 20 50 2e 20 4a | 2e 20 50 6c 61 75 67 65 |and P. J|. Plauge|
|00001040| 72 3a 20 22 53 6f 66 74 | 77 61 72 65 20 54 6f 6f |r: "Soft|ware Too|
|00001050| 6c 73 20 69 6e 20 50 61 | 73 63 61 6c 22 2c 0a 20 |ls in Pa|scal",. |
|00001060| 20 20 20 20 41 64 64 69 | 73 6f 6e 2d 57 65 73 6c | Addi|son-Wesl|
|00001070| 65 79 2c 20 31 39 38 31 | 2e 0a 0a 20 20 20 49 66 |ey, 1981|... If|
|00001080| 20 69 6e 76 6f 6b 65 64 | 20 77 69 74 68 20 61 20 | invoked| with a |
|00001090| 46 49 4c 45 20 61 72 67 | 75 6d 65 6e 74 2c 20 74 |FILE arg|ument, t|
|000010a0| 68 65 6e 20 61 20 63 6f | 70 79 20 6f 66 20 46 49 |hen a co|py of FI|
|000010b0| 4c 45 20 69 73 20 72 65 | 61 64 20 69 6e 74 6f 0a |LE is re|ad into.|
|000010c0| 74 68 65 20 65 64 69 74 | 6f 72 27 73 20 62 75 66 |the edit|or's buf|
|000010d0| 66 65 72 2e 20 20 43 68 | 61 6e 67 65 73 20 61 72 |fer. Ch|anges ar|
|000010e0| 65 20 6d 61 64 65 20 74 | 6f 20 74 68 69 73 20 63 |e made t|o this c|
|000010f0| 6f 70 79 20 61 6e 64 20 | 6e 6f 74 20 64 69 72 65 |opy and |not dire|
|00001100| 63 74 6c 79 20 74 6f 0a | 46 49 4c 45 20 69 74 73 |ctly to.|FILE its|
|00001110| 65 6c 66 2e 20 20 55 70 | 6f 6e 20 71 75 69 74 74 |elf. Up|on quitt|
|00001120| 69 6e 67 20 60 65 64 27 | 2c 20 61 6e 79 20 63 68 |ing `ed'|, any ch|
|00001130| 61 6e 67 65 73 20 6e 6f | 74 20 65 78 70 6c 69 63 |anges no|t explic|
|00001140| 69 74 6c 79 20 73 61 76 | 65 64 20 77 69 74 68 0a |itly sav|ed with.|
|00001150| 61 20 60 77 27 20 63 6f | 6d 6d 61 6e 64 20 61 72 |a `w' co|mmand ar|
|00001160| 65 20 6c 6f 73 74 2e 0a | 0a 20 20 20 45 64 69 74 |e lost..|. Edit|
|00001170| 69 6e 67 20 69 73 20 64 | 6f 6e 65 20 69 6e 20 74 |ing is d|one in t|
|00001180| 77 6f 20 64 69 73 74 69 | 6e 63 74 20 6d 6f 64 65 |wo disti|nct mode|
|00001190| 73 3a 20 22 63 6f 6d 6d | 61 6e 64 22 20 61 6e 64 |s: "comm|and" and|
|000011a0| 20 22 69 6e 70 75 74 22 | 2e 20 20 57 68 65 6e 0a | "input"|. When.|
|000011b0| 66 69 72 73 74 20 69 6e | 76 6f 6b 65 64 2c 20 60 |first in|voked, `|
|000011c0| 65 64 27 20 69 73 20 69 | 6e 20 63 6f 6d 6d 61 6e |ed' is i|n comman|
|000011d0| 64 20 6d 6f 64 65 2e 20 | 20 49 6e 20 74 68 69 73 |d mode. | In this|
|000011e0| 20 6d 6f 64 65 20 63 6f | 6d 6d 61 6e 64 73 20 61 | mode co|mmands a|
|000011f0| 72 65 20 72 65 61 64 0a | 66 72 6f 6d 20 74 68 65 |re read.|from the|
|00001200| 20 73 74 61 6e 64 61 72 | 64 20 69 6e 70 75 74 20 | standar|d input |
|00001210| 61 6e 64 20 65 78 65 63 | 75 74 65 64 20 74 6f 20 |and exec|uted to |
|00001220| 6d 61 6e 69 70 75 6c 61 | 74 65 20 74 68 65 20 63 |manipula|te the c|
|00001230| 6f 6e 74 65 6e 74 73 20 | 6f 66 20 74 68 65 0a 65 |ontents |of the.e|
|00001240| 64 69 74 6f 72 20 62 75 | 66 66 65 72 2e 20 20 41 |ditor bu|ffer. A|
|00001250| 20 74 79 70 69 63 61 6c | 20 63 6f 6d 6d 61 6e 64 | typical| command|
|00001260| 20 6d 69 67 68 74 20 6c | 6f 6f 6b 20 6c 69 6b 65 | might l|ook like|
|00001270| 3a 0a 0a 20 20 20 20 20 | 2c 73 2f 4f 4c 44 2f 4e |:.. |,s/OLD/N|
|00001280| 45 57 2f 67 0a 0a 77 68 | 69 63 68 20 72 65 70 6c |EW/g..wh|ich repl|
|00001290| 61 63 65 73 20 61 6c 6c | 20 6f 63 63 75 72 65 6e |aces all| occuren|
|000012a0| 63 65 73 20 6f 66 20 74 | 68 65 20 73 74 72 69 6e |ces of t|he strin|
|000012b0| 67 20 4f 4c 44 20 77 69 | 74 68 20 4e 45 57 2e 0a |g OLD wi|th NEW..|
|000012c0| 0a 20 20 20 57 68 65 6e | 20 61 6e 20 69 6e 70 75 |. When| an inpu|
|000012d0| 74 20 63 6f 6d 6d 61 6e | 64 2c 20 73 75 63 68 20 |t comman|d, such |
|000012e0| 61 73 20 60 61 27 20 28 | 61 70 70 65 6e 64 29 2c |as `a' (|append),|
|000012f0| 20 60 69 27 20 28 69 6e | 73 65 72 74 29 20 6f 72 | `i' (in|sert) or|
|00001300| 20 60 63 27 0a 28 63 68 | 61 6e 67 65 29 2c 20 69 | `c'.(ch|ange), i|
|00001310| 73 20 67 69 76 65 6e 2c | 20 60 65 64 27 20 65 6e |s given,| `ed' en|
|00001320| 74 65 72 73 20 69 6e 70 | 75 74 20 6d 6f 64 65 2e |ters inp|ut mode.|
|00001330| 20 20 54 68 69 73 20 69 | 73 20 74 68 65 20 70 72 | This i|s the pr|
|00001340| 69 6d 61 72 79 20 6d 65 | 61 6e 73 0a 6f 66 20 61 |imary me|ans.of a|
|00001350| 64 64 69 6e 67 20 74 65 | 78 74 20 74 6f 20 61 20 |dding te|xt to a |
|00001360| 66 69 6c 65 2e 20 20 49 | 6e 20 74 68 69 73 20 6d |file. I|n this m|
|00001370| 6f 64 65 2c 20 6e 6f 20 | 63 6f 6d 6d 61 6e 64 73 |ode, no |commands|
|00001380| 20 61 72 65 20 61 76 61 | 69 6c 61 62 6c 65 3b 0a | are ava|ilable;.|
|00001390| 69 6e 73 74 65 61 64 2c | 20 74 68 65 20 73 74 61 |instead,| the sta|
|000013a0| 6e 64 61 72 64 20 69 6e | 70 75 74 20 69 73 20 77 |ndard in|put is w|
|000013b0| 72 69 74 74 65 6e 20 64 | 69 72 65 63 74 6c 79 20 |ritten d|irectly |
|000013c0| 74 6f 20 74 68 65 20 65 | 64 69 74 6f 72 20 62 75 |to the e|ditor bu|
|000013d0| 66 66 65 72 2e 0a 54 68 | 65 20 74 65 78 74 20 75 |ffer..Th|e text u|
|000013e0| 70 20 74 6f 20 61 6e 64 | 20 69 6e 63 6c 75 64 69 |p to and| includi|
|000013f0| 6e 67 20 61 20 6e 65 77 | 6c 69 6e 65 20 63 68 61 |ng a new|line cha|
|00001400| 72 61 63 74 65 72 20 64 | 65 66 69 6e 65 73 20 61 |racter d|efines a|
|00001410| 20 73 69 6e 67 6c 65 20 | 6c 69 6e 65 2e 0a 49 6e | single |line..In|
|00001420| 70 75 74 20 6d 6f 64 65 | 20 69 73 20 74 65 72 6d |put mode| is term|
|00001430| 69 6e 61 74 65 64 20 62 | 79 20 65 6e 74 65 72 69 |inated b|y enteri|
|00001440| 6e 67 20 61 20 73 69 6e | 67 6c 65 20 70 65 72 69 |ng a sin|gle peri|
|00001450| 6f 64 20 28 60 2e 27 29 | 20 6f 6e 20 61 20 6c 69 |od (`.')| on a li|
|00001460| 6e 65 2e 0a 0a 20 20 20 | 41 6c 6c 20 60 65 64 27 |ne... |All `ed'|
|00001470| 20 63 6f 6d 6d 61 6e 64 | 73 20 6f 70 65 72 61 74 | command|s operat|
|00001480| 65 20 6f 6e 20 77 68 6f | 6c 65 20 6c 69 6e 65 73 |e on who|le lines|
|00001490| 20 6f 72 20 72 61 6e 67 | 65 73 20 6f 66 20 6c 69 | or rang|es of li|
|000014a0| 6e 65 73 3b 20 65 2e 67 | 2e 2c 0a 74 68 65 20 60 |nes; e.g|.,.the `|
|000014b0| 64 27 20 63 6f 6d 6d 61 | 6e 64 20 64 65 6c 65 74 |d' comma|nd delet|
|000014c0| 65 73 20 6c 69 6e 65 73 | 3b 20 74 68 65 20 60 6d |es lines|; the `m|
|000014d0| 27 20 63 6f 6d 6d 61 6e | 64 20 6d 6f 76 65 73 20 |' comman|d moves |
|000014e0| 6c 69 6e 65 73 2c 20 61 | 6e 64 20 73 6f 20 6f 6e |lines, a|nd so on|
|000014f0| 2e 0a 49 74 20 69 73 20 | 70 6f 73 73 69 62 6c 65 |..It is |possible|
|00001500| 20 74 6f 20 6d 6f 64 69 | 66 79 20 6f 6e 6c 79 20 | to modi|fy only |
|00001510| 61 20 70 6f 72 74 69 6f | 6e 20 6f 66 20 61 20 6c |a portio|n of a l|
|00001520| 69 6e 65 20 62 79 20 6d | 65 61 6e 73 20 6f 66 0a |ine by m|eans of.|
|00001530| 72 65 70 6c 61 63 65 6d | 65 6e 74 2c 20 61 73 20 |replacem|ent, as |
|00001540| 69 6e 20 74 68 65 20 65 | 78 61 6d 70 6c 65 20 61 |in the e|xample a|
|00001550| 62 6f 76 65 2e 20 20 48 | 6f 77 65 76 65 72 20 65 |bove. H|owever e|
|00001560| 76 65 6e 20 68 65 72 65 | 2c 20 74 68 65 20 60 73 |ven here|, the `s|
|00001570| 27 0a 63 6f 6d 6d 61 6e | 64 20 69 73 20 61 70 70 |'.comman|d is app|
|00001580| 6c 69 65 64 20 74 6f 20 | 77 68 6f 6c 65 20 6c 69 |lied to |whole li|
|00001590| 6e 65 73 20 61 74 20 61 | 20 74 69 6d 65 2e 0a 0a |nes at a| time...|
|000015a0| 20 20 20 49 6e 20 67 65 | 6e 65 72 61 6c 2c 20 60 | In ge|neral, `|
|000015b0| 65 64 27 20 63 6f 6d 6d | 61 6e 64 73 20 63 6f 6e |ed' comm|ands con|
|000015c0| 73 69 73 74 20 6f 66 20 | 7a 65 72 6f 20 6f 72 20 |sist of |zero or |
|000015d0| 6d 6f 72 65 20 6c 69 6e | 65 20 61 64 64 72 65 73 |more lin|e addres|
|000015e0| 73 65 73 2c 0a 66 6f 6c | 6c 6f 77 65 64 20 62 79 |ses,.fol|lowed by|
|000015f0| 20 61 20 73 69 6e 67 6c | 65 20 63 68 61 72 61 63 | a singl|e charac|
|00001600| 74 65 72 20 63 6f 6d 6d | 61 6e 64 20 61 6e 64 20 |ter comm|and and |
|00001610| 70 6f 73 73 69 62 6c 79 | 20 61 64 64 69 74 69 6f |possibly| additio|
|00001620| 6e 61 6c 0a 70 61 72 61 | 6d 65 74 65 72 73 3b 20 |nal.para|meters; |
|00001630| 69 2e 65 2e 2c 20 63 6f | 6d 6d 61 6e 64 73 20 68 |i.e., co|mmands h|
|00001640| 61 76 65 20 74 68 65 20 | 73 74 72 75 63 74 75 72 |ave the |structur|
|00001650| 65 3a 0a 0a 20 20 20 20 | 20 5b 41 44 44 52 45 53 |e:.. | [ADDRES|
|00001660| 53 20 5b 2c 41 44 44 52 | 45 53 53 5d 5d 43 4f 4d |S [,ADDR|ESS]]COM|
|00001670| 4d 41 4e 44 5b 50 41 52 | 41 4d 45 54 45 52 53 5d |MAND[PAR|AMETERS]|
|00001680| 0a 0a 20 20 20 54 68 65 | 20 41 44 44 52 45 53 53 |.. The| ADDRESS|
|00001690| 28 65 73 29 20 69 6e 64 | 69 63 61 74 65 20 74 68 |(es) ind|icate th|
|000016a0| 65 20 6c 69 6e 65 20 6f | 72 20 72 61 6e 67 65 20 |e line o|r range |
|000016b0| 6f 66 20 6c 69 6e 65 73 | 20 74 6f 20 62 65 20 61 |of lines| to be a|
|000016c0| 66 66 65 63 74 65 64 0a | 62 79 20 74 68 65 20 63 |ffected.|by the c|
|000016d0| 6f 6d 6d 61 6e 64 2e 20 | 20 49 66 20 66 65 77 65 |ommand. | If fewe|
|000016e0| 72 20 61 64 64 72 65 73 | 73 65 73 20 61 72 65 20 |r addres|ses are |
|000016f0| 67 69 76 65 6e 20 74 68 | 61 6e 20 74 68 65 20 63 |given th|an the c|
|00001700| 6f 6d 6d 61 6e 64 20 61 | 63 63 65 70 74 73 2c 0a |ommand a|ccepts,.|
|00001710| 74 68 65 6e 20 64 65 66 | 61 75 6c 74 20 61 64 64 |then def|ault add|
|00001720| 72 65 73 73 65 73 20 61 | 72 65 20 73 75 70 70 6c |resses a|re suppl|
|00001730| 69 65 64 2e 0a 0a 1f 0a | 46 69 6c 65 3a 20 65 64 |ied.....|File: ed|
|00001740| 2e 69 6e 66 6f 2c 20 20 | 4e 6f 64 65 3a 20 49 6e |.info, |Node: In|
|00001750| 76 6f 6b 69 6e 67 2c 20 | 20 4e 65 78 74 3a 20 4c |voking, | Next: L|
|00001760| 69 6e 65 20 61 64 64 72 | 65 73 73 69 6e 67 2c 20 |ine addr|essing, |
|00001770| 20 50 72 65 76 3a 20 44 | 65 73 63 72 69 70 74 69 | Prev: D|escripti|
|00001780| 6f 6e 2c 20 20 55 70 3a | 20 54 6f 70 0a 0a 49 6e |on, Up:| Top..In|
|00001790| 76 6f 6b 69 6e 67 20 47 | 4e 55 20 60 65 64 27 0a |voking G|NU `ed'.|
|000017a0| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|000017b0| 2a 0a 0a 20 20 20 20 20 | 65 64 20 5b 2d 5d 20 5b |*.. |ed [-] [|
|000017c0| 2d 47 73 5d 20 5b 2d 70 | 20 53 54 52 49 4e 47 5d |-Gs] [-p| STRING]|
|000017d0| 20 5b 46 49 4c 45 5d 0a | 20 20 20 20 20 72 65 64 | [FILE].| red|
|000017e0| 20 5b 2d 5d 20 5b 2d 47 | 73 5d 20 5b 2d 70 20 53 | [-] [-G|s] [-p S|
|000017f0| 54 52 49 4e 47 5d 20 5b | 46 49 4c 45 5d 0a 0a 60 |TRING] [|FILE]..`|
|00001800| 2d 47 27 0a 20 20 20 20 | 20 46 6f 72 63 65 73 20 |-G'. | Forces |
|00001810| 62 61 63 6b 77 61 72 64 | 73 20 63 6f 6d 70 61 74 |backward|s compat|
|00001820| 69 62 69 6c 69 74 79 2e | 20 20 54 68 69 73 20 61 |ibility.| This a|
|00001830| 66 66 65 63 74 73 20 74 | 68 65 20 62 65 68 61 76 |ffects t|he behav|
|00001840| 69 6f 72 20 6f 66 20 74 | 68 65 0a 20 20 20 20 20 |ior of t|he. |
|00001850| 60 65 64 27 20 63 6f 6d | 6d 61 6e 64 73 20 60 47 |`ed' com|mands `G|
|00001860| 27 2c 20 60 66 27 2c 20 | 60 6c 27 2c 20 60 6d 27 |', `f', |`l', `m'|
|00001870| 2c 20 60 74 27 20 61 6e | 64 20 60 21 21 27 2e 20 |, `t' an|d `!!'. |
|00001880| 20 49 66 20 74 68 65 20 | 64 65 66 61 75 6c 74 0a | If the |default.|
|00001890| 20 20 20 20 20 62 65 68 | 61 76 69 6f 72 20 6f 66 | beh|avior of|
|000018a0| 20 74 68 65 73 65 20 63 | 6f 6d 6d 61 6e 64 73 20 | these c|ommands |
|000018b0| 64 6f 65 73 20 6e 6f 74 | 20 73 65 65 6d 20 66 61 |does not| seem fa|
|000018c0| 6d 69 6c 69 61 72 2c 20 | 74 68 65 6e 20 74 72 79 |miliar, |then try|
|000018d0| 0a 20 20 20 20 20 69 6e | 76 6f 6b 69 6e 67 20 60 |. in|voking `|
|000018e0| 65 64 27 20 77 69 74 68 | 20 74 68 69 73 20 73 77 |ed' with| this sw|
|000018f0| 69 74 63 68 2e 0a 0a 60 | 2d 73 27 0a 60 2d 27 0a |itch...`|-s'.`-'.|
|00001900| 20 20 20 20 20 53 75 70 | 70 72 65 73 73 65 73 20 | Sup|presses |
|00001910| 64 69 61 67 6e 6f 73 74 | 69 63 73 2e 20 54 68 69 |diagnost|ics. Thi|
|00001920| 73 20 73 68 6f 75 6c 64 | 20 62 65 20 75 73 65 64 |s should| be used|
|00001930| 20 69 66 20 60 65 64 27 | 27 73 20 73 74 61 6e 64 | if `ed'|'s stand|
|00001940| 61 72 64 0a 20 20 20 20 | 20 69 6e 70 75 74 20 69 |ard. | input i|
|00001950| 73 20 66 72 6f 6d 20 61 | 20 73 63 72 69 70 74 2e |s from a| script.|
|00001960| 0a 0a 60 2d 70 20 53 54 | 52 49 4e 47 27 0a 20 20 |..`-p ST|RING'. |
|00001970| 20 20 20 53 70 65 63 69 | 66 69 65 73 20 61 20 63 | Speci|fies a c|
|00001980| 6f 6d 6d 61 6e 64 20 70 | 72 6f 6d 70 74 2e 20 20 |ommand p|rompt. |
|00001990| 54 68 69 73 20 6d 61 79 | 20 62 65 20 74 6f 67 67 |This may| be togg|
|000019a0| 6c 65 64 20 6f 6e 20 61 | 6e 64 20 6f 66 66 20 77 |led on a|nd off w|
|000019b0| 69 74 68 0a 20 20 20 20 | 20 74 68 65 20 60 50 27 |ith. | the `P'|
|000019c0| 20 63 6f 6d 6d 61 6e 64 | 2e 0a 0a 20 20 20 46 49 | command|... FI|
|000019d0| 4c 45 20 73 70 65 63 69 | 66 69 65 73 20 74 68 65 |LE speci|fies the|
|000019e0| 20 6e 61 6d 65 20 6f 66 | 20 61 20 66 69 6c 65 20 | name of| a file |
|000019f0| 74 6f 20 72 65 61 64 2e | 20 20 49 66 20 46 49 4c |to read.| If FIL|
|00001a00| 45 20 69 73 20 70 72 65 | 66 69 78 65 64 20 77 69 |E is pre|fixed wi|
|00001a10| 74 68 0a 61 20 62 61 6e | 67 20 28 21 29 2c 20 74 |th.a ban|g (!), t|
|00001a20| 68 65 6e 20 69 74 20 69 | 73 20 69 6e 74 65 72 70 |hen it i|s interp|
|00001a30| 72 65 74 65 64 20 61 73 | 20 61 20 73 68 65 6c 6c |reted as| a shell|
|00001a40| 20 63 6f 6d 6d 61 6e 64 | 2e 20 20 49 6e 20 74 68 | command|. In th|
|00001a50| 69 73 20 63 61 73 65 2c | 0a 77 68 61 74 20 69 73 |is case,|.what is|
|00001a60| 20 72 65 61 64 20 69 73 | 20 74 68 65 20 73 74 61 | read is| the sta|
|00001a70| 6e 64 61 72 64 20 6f 75 | 74 70 75 74 20 6f 66 20 |ndard ou|tput of |
|00001a80| 46 49 4c 45 20 65 78 65 | 63 75 74 65 64 20 76 69 |FILE exe|cuted vi|
|00001a90| 61 20 60 73 68 20 28 31 | 29 27 2e 20 20 54 6f 0a |a `sh (1|)'. To.|
|00001aa0| 72 65 61 64 20 61 20 66 | 69 6c 65 20 77 68 6f 73 |read a f|ile whos|
|00001ab0| 65 20 6e 61 6d 65 20 62 | 65 67 69 6e 73 20 77 69 |e name b|egins wi|
|00001ac0| 74 68 20 61 20 62 61 6e | 67 2c 20 70 72 65 66 69 |th a ban|g, prefi|
|00001ad0| 78 20 74 68 65 20 6e 61 | 6d 65 20 77 69 74 68 20 |x the na|me with |
|00001ae0| 61 0a 62 61 63 6b 73 6c | 61 73 68 20 28 60 5c 27 |a.backsl|ash (`\'|
|00001af0| 29 2e 20 20 54 68 65 20 | 64 65 66 61 75 6c 74 20 |). The |default |
|00001b00| 66 69 6c 65 6e 61 6d 65 | 20 69 73 20 73 65 74 20 |filename| is set |
|00001b10| 74 6f 20 46 49 4c 45 20 | 6f 6e 6c 79 20 69 66 20 |to FILE |only if |
|00001b20| 69 74 20 69 73 20 6e 6f | 74 0a 70 72 65 66 69 78 |it is no|t.prefix|
|00001b30| 65 64 20 77 69 74 68 20 | 61 20 62 61 6e 67 2e 0a |ed with |a bang..|
|00001b40| 0a 1f 0a 46 69 6c 65 3a | 20 65 64 2e 69 6e 66 6f |...File:| ed.info|
|00001b50| 2c 20 20 4e 6f 64 65 3a | 20 4c 69 6e 65 20 61 64 |, Node:| Line ad|
|00001b60| 64 72 65 73 73 69 6e 67 | 2c 20 20 4e 65 78 74 3a |dressing|, Next:|
|00001b70| 20 52 65 67 75 6c 61 72 | 20 65 78 70 72 65 73 73 | Regular| express|
|00001b80| 69 6f 6e 73 2c 20 20 50 | 72 65 76 3a 20 49 6e 76 |ions, P|rev: Inv|
|00001b90| 6f 6b 69 6e 67 2c 20 20 | 55 70 3a 20 54 6f 70 0a |oking, |Up: Top.|
|00001ba0| 0a 4c 69 6e 65 20 61 64 | 64 72 65 73 73 69 6e 67 |.Line ad|dressing|
|00001bb0| 0a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |.*******|********|
|00001bc0| 0a 0a 20 20 20 41 6e 20 | 61 64 64 72 65 73 73 20 |.. An |address |
|00001bd0| 72 65 70 72 65 73 65 6e | 74 73 20 74 68 65 20 6e |represen|ts the n|
|00001be0| 75 6d 62 65 72 20 6f 66 | 20 61 20 6c 69 6e 65 20 |umber of| a line |
|00001bf0| 69 6e 20 74 68 65 20 62 | 75 66 66 65 72 2e 20 20 |in the b|uffer. |
|00001c00| 60 65 64 27 0a 6d 61 69 | 6e 74 61 69 6e 73 20 61 |`ed'.mai|ntains a|
|00001c10| 20 22 63 75 72 72 65 6e | 74 20 61 64 64 72 65 73 | "curren|t addres|
|00001c20| 73 22 20 77 68 69 63 68 | 20 69 73 20 74 79 70 69 |s" which| is typi|
|00001c30| 63 61 6c 6c 79 20 73 75 | 70 70 6c 69 65 64 20 74 |cally su|pplied t|
|00001c40| 6f 20 63 6f 6d 6d 61 6e | 64 73 0a 61 73 20 74 68 |o comman|ds.as th|
|00001c50| 65 20 64 65 66 61 75 6c | 74 20 61 64 64 72 65 73 |e defaul|t addres|
|00001c60| 73 20 77 68 65 6e 20 6e | 6f 6e 65 20 69 73 20 73 |s when n|one is s|
|00001c70| 70 65 63 69 66 69 65 64 | 2e 20 20 57 68 65 6e 20 |pecified|. When |
|00001c80| 61 20 66 69 6c 65 20 69 | 73 20 66 69 72 73 74 0a |a file i|s first.|
|00001c90| 72 65 61 64 2c 20 74 68 | 65 20 63 75 72 72 65 6e |read, th|e curren|
|00001ca0| 74 20 61 64 64 72 65 73 | 73 20 69 73 20 73 65 74 |t addres|s is set|
|00001cb0| 20 74 6f 20 74 68 65 20 | 6c 61 73 74 20 6c 69 6e | to the |last lin|
|00001cc0| 65 20 6f 66 20 74 68 65 | 20 66 69 6c 65 2e 20 20 |e of the| file. |
|00001cd0| 49 6e 0a 67 65 6e 65 72 | 61 6c 2c 20 74 68 65 20 |In.gener|al, the |
|00001ce0| 63 75 72 72 65 6e 74 20 | 61 64 64 72 65 73 73 20 |current |address |
|00001cf0| 69 73 20 73 65 74 20 74 | 6f 20 74 68 65 20 6c 61 |is set t|o the la|
|00001d00| 73 74 20 6c 69 6e 65 20 | 61 66 66 65 63 74 65 64 |st line |affected|
|00001d10| 20 62 79 20 61 0a 63 6f | 6d 6d 61 6e 64 2e 0a 0a | by a.co|mmand...|
|00001d20| 20 20 20 41 20 6c 69 6e | 65 20 61 64 64 72 65 73 | A lin|e addres|
|00001d30| 73 20 69 73 20 63 6f 6e | 73 74 72 75 63 74 65 64 |s is con|structed|
|00001d40| 20 66 72 6f 6d 20 6f 6e | 65 20 6f 66 20 74 68 65 | from on|e of the|
|00001d50| 20 62 61 73 65 73 20 69 | 6e 20 74 68 65 20 6c 69 | bases i|n the li|
|00001d60| 73 74 0a 62 65 6c 6f 77 | 2c 20 6f 70 74 69 6f 6e |st.below|, option|
|00001d70| 61 6c 6c 79 20 66 6f 6c | 6c 6f 77 65 64 20 62 79 |ally fol|lowed by|
|00001d80| 20 61 20 6e 75 6d 65 72 | 69 63 20 6f 66 66 73 65 | a numer|ic offse|
|00001d90| 74 2e 20 20 54 68 65 20 | 6f 66 66 73 65 74 20 6d |t. The |offset m|
|00001da0| 61 79 20 69 6e 63 6c 75 | 64 65 0a 61 6e 79 20 63 |ay inclu|de.any c|
|00001db0| 6f 6d 62 69 6e 61 74 69 | 6f 6e 20 6f 66 20 64 69 |ombinati|on of di|
|00001dc0| 67 69 74 73 2c 20 6f 70 | 65 72 61 74 6f 72 73 20 |gits, op|erators |
|00001dd0| 28 69 2e 65 2e 2c 20 60 | 2b 27 2c 20 60 2d 27 20 |(i.e., `|+', `-' |
|00001de0| 61 6e 64 20 60 5e 27 29 | 20 61 6e 64 0a 77 68 69 |and `^')| and.whi|
|00001df0| 74 65 73 70 61 63 65 2e | 20 20 41 64 64 72 65 73 |tespace.| Addres|
|00001e00| 73 65 73 20 61 72 65 20 | 72 65 61 64 20 66 72 6f |ses are |read fro|
|00001e10| 6d 20 6c 65 66 74 20 74 | 6f 20 72 69 67 68 74 2c |m left t|o right,|
|00001e20| 20 61 6e 64 20 74 68 65 | 69 72 20 76 61 6c 75 65 | and the|ir value|
|00001e30| 73 0a 61 72 65 20 63 6f | 6d 70 75 74 65 64 20 72 |s.are co|mputed r|
|00001e40| 65 6c 61 74 69 76 65 20 | 74 6f 20 74 68 65 20 63 |elative |to the c|
|00001e50| 75 72 72 65 6e 74 20 61 | 64 64 72 65 73 73 2e 0a |urrent a|ddress..|
|00001e60| 0a 20 20 20 4f 6e 65 20 | 65 78 63 65 70 74 69 6f |. One |exceptio|
|00001e70| 6e 20 74 6f 20 74 68 65 | 20 72 75 6c 65 20 74 68 |n to the| rule th|
|00001e80| 61 74 20 61 64 64 72 65 | 73 73 65 73 20 72 65 70 |at addre|sses rep|
|00001e90| 72 65 73 65 6e 74 20 6c | 69 6e 65 20 6e 75 6d 62 |resent l|ine numb|
|00001ea0| 65 72 73 20 69 73 0a 74 | 68 65 20 61 64 64 72 65 |ers is.t|he addre|
|00001eb0| 73 73 20 60 30 27 20 28 | 7a 65 72 6f 29 2e 20 20 |ss `0' (|zero). |
|00001ec0| 54 68 69 73 20 6d 65 61 | 6e 73 20 22 62 65 66 6f |This mea|ns "befo|
|00001ed0| 72 65 20 74 68 65 20 66 | 69 72 73 74 20 6c 69 6e |re the f|irst lin|
|00001ee0| 65 2c 22 20 61 6e 64 20 | 69 73 0a 6c 65 67 61 6c |e," and |is.legal|
|00001ef0| 20 77 68 65 72 65 76 65 | 72 20 69 74 20 6d 61 6b | whereve|r it mak|
|00001f00| 65 73 20 73 65 6e 73 65 | 2e 0a 0a 20 20 20 41 6e |es sense|... An|
|00001f10| 20 61 64 64 72 65 73 73 | 20 72 61 6e 67 65 20 69 | address| range i|
|00001f20| 73 20 74 77 6f 20 61 64 | 64 72 65 73 73 65 73 20 |s two ad|dresses |
|00001f30| 73 65 70 61 72 61 74 65 | 64 20 65 69 74 68 65 72 |separate|d either|
|00001f40| 20 62 79 20 61 20 63 6f | 6d 6d 61 20 6f 72 0a 73 | by a co|mma or.s|
|00001f50| 65 6d 69 2d 63 6f 6c 6f | 6e 2e 20 54 68 65 20 76 |emi-colo|n. The v|
|00001f60| 61 6c 75 65 20 6f 66 20 | 74 68 65 20 66 69 72 73 |alue of |the firs|
|00001f70| 74 20 61 64 64 72 65 73 | 73 20 69 6e 20 61 20 72 |t addres|s in a r|
|00001f80| 61 6e 67 65 20 63 61 6e | 6e 6f 74 20 65 78 63 65 |ange can|not exce|
|00001f90| 65 64 20 74 68 65 0a 76 | 61 6c 75 65 20 6f 66 20 |ed the.v|alue of |
|00001fa0| 74 68 65 20 74 68 65 20 | 73 65 63 6f 6e 64 2e 20 |the the |second. |
|00001fb0| 20 49 66 20 6f 6e 6c 79 | 20 6f 6e 65 20 61 64 64 | If only| one add|
|00001fc0| 72 65 73 73 20 69 73 20 | 67 69 76 65 6e 20 69 6e |ress is |given in|
|00001fd0| 20 61 20 72 61 6e 67 65 | 2c 20 74 68 65 6e 0a 74 | a range|, then.t|
|00001fe0| 68 65 20 73 65 63 6f 6e | 64 20 61 64 64 72 65 73 |he secon|d addres|
|00001ff0| 73 20 69 73 20 73 65 74 | 20 74 6f 20 74 68 65 20 |s is set| to the |
|00002000| 67 69 76 65 6e 20 61 64 | 64 72 65 73 73 2e 20 20 |given ad|dress. |
|00002010| 49 66 20 61 6e 20 4e 2d | 74 75 70 6c 65 20 6f 66 |If an N-|tuple of|
|00002020| 0a 61 64 64 72 65 73 73 | 65 73 20 69 73 20 67 69 |.address|es is gi|
|00002030| 76 65 6e 20 77 68 65 72 | 65 20 4e 20 3e 20 32 2c |ven wher|e N > 2,|
|00002040| 20 74 68 65 6e 20 74 68 | 65 20 63 6f 72 72 65 73 | then th|e corres|
|00002050| 70 6f 6e 64 69 6e 67 20 | 72 61 6e 67 65 20 69 73 |ponding |range is|
|00002060| 0a 64 65 74 65 72 6d 69 | 6e 65 64 20 62 79 20 74 |.determi|ned by t|
|00002070| 68 65 20 6c 61 73 74 20 | 74 77 6f 20 61 64 64 72 |he last |two addr|
|00002080| 65 73 73 65 73 20 69 6e | 20 74 68 65 20 4e 2d 74 |esses in| the N-t|
|00002090| 75 70 6c 65 2e 20 20 49 | 66 20 6f 6e 6c 79 20 6f |uple. I|f only o|
|000020a0| 6e 65 0a 61 64 64 72 65 | 73 73 20 69 73 20 65 78 |ne.addre|ss is ex|
|000020b0| 70 65 63 74 65 64 2c 20 | 74 68 65 6e 20 74 68 65 |pected, |then the|
|000020c0| 20 6c 61 73 74 20 61 64 | 64 72 65 73 73 20 69 73 | last ad|dress is|
|000020d0| 20 75 73 65 64 2e 0a 0a | 20 20 20 45 61 63 68 20 | used...| Each |
|000020e0| 61 64 64 72 65 73 73 20 | 69 6e 20 61 20 63 6f 6d |address |in a com|
|000020f0| 6d 61 2d 64 65 6c 69 6d | 69 74 65 64 20 72 61 6e |ma-delim|ited ran|
|00002100| 67 65 20 69 73 20 69 6e | 74 65 72 70 72 65 74 65 |ge is in|terprete|
|00002110| 64 20 72 65 6c 61 74 69 | 76 65 20 74 6f 0a 74 68 |d relati|ve to.th|
|00002120| 65 20 63 75 72 72 65 6e | 74 20 61 64 64 72 65 73 |e curren|t addres|
|00002130| 73 2e 20 20 49 6e 20 61 | 20 73 65 6d 69 2d 63 6f |s. In a| semi-co|
|00002140| 6c 6f 6e 2d 64 65 6c 69 | 6d 69 74 65 64 20 72 61 |lon-deli|mited ra|
|00002150| 6e 67 65 2c 20 74 68 65 | 20 66 69 72 73 74 0a 61 |nge, the| first.a|
|00002160| 64 64 72 65 73 73 20 69 | 73 20 75 73 65 64 20 74 |ddress i|s used t|
|00002170| 6f 20 73 65 74 20 74 68 | 65 20 63 75 72 72 65 6e |o set th|e curren|
|00002180| 74 20 61 64 64 72 65 73 | 73 2c 20 61 6e 64 20 74 |t addres|s, and t|
|00002190| 68 65 20 73 65 63 6f 6e | 64 20 61 64 64 72 65 73 |he secon|d addres|
|000021a0| 73 20 69 73 0a 69 6e 74 | 65 72 70 72 65 74 65 64 |s is.int|erpreted|
|000021b0| 20 72 65 6c 61 74 69 76 | 65 20 74 6f 20 74 68 65 | relativ|e to the|
|000021c0| 20 66 69 72 73 74 2e 0a | 0a 20 20 20 54 68 65 20 | first..|. The |
|000021d0| 66 6f 6c 6c 6f 77 69 6e | 67 20 61 64 64 72 65 73 |followin|g addres|
|000021e0| 73 20 73 79 6d 62 6f 6c | 73 20 61 72 65 20 72 65 |s symbol|s are re|
|000021f0| 63 6f 67 6e 69 7a 65 64 | 2e 0a 0a 60 2e 27 0a 20 |cognized|...`.'. |
|00002200| 20 20 20 20 54 68 65 20 | 63 75 72 72 65 6e 74 20 | The |current |
|00002210| 6c 69 6e 65 20 28 61 64 | 64 72 65 73 73 29 20 69 |line (ad|dress) i|
|00002220| 6e 20 74 68 65 20 62 75 | 66 66 65 72 2e 0a 0a 60 |n the bu|ffer...`|
|00002230| 24 27 0a 20 20 20 20 20 | 54 68 65 20 6c 61 73 74 |$'. |The last|
|00002240| 20 6c 69 6e 65 20 69 6e | 20 74 68 65 20 62 75 66 | line in| the buf|
|00002250| 66 65 72 2e 0a 0a 60 4e | 27 0a 20 20 20 20 20 54 |fer...`N|'. T|
|00002260| 68 65 20 4e 74 68 2c 20 | 6c 69 6e 65 20 69 6e 20 |he Nth, |line in |
|00002270| 74 68 65 20 62 75 66 66 | 65 72 20 77 68 65 72 65 |the buff|er where|
|00002280| 20 4e 20 69 73 20 61 20 | 6e 75 6d 62 65 72 20 69 | N is a |number i|
|00002290| 6e 20 74 68 65 20 72 61 | 6e 67 65 20 60 30 2c 24 |n the ra|nge `0,$|
|000022a0| 27 2e 0a 0a 60 2d 27 0a | 60 5e 27 0a 20 20 20 20 |'...`-'.|`^'. |
|000022b0| 20 54 68 65 20 70 72 65 | 76 69 6f 75 73 20 6c 69 | The pre|vious li|
|000022c0| 6e 65 2e 20 20 54 68 69 | 73 20 69 73 20 65 71 75 |ne. Thi|s is equ|
|000022d0| 69 76 61 6c 65 6e 74 20 | 74 6f 20 60 2d 31 27 20 |ivalent |to `-1' |
|000022e0| 61 6e 64 20 6d 61 79 20 | 62 65 20 72 65 70 65 61 |and may |be repea|
|000022f0| 74 65 64 0a 20 20 20 20 | 20 77 69 74 68 20 63 75 |ted. | with cu|
|00002300| 6d 75 6c 61 74 69 76 65 | 20 65 66 66 65 63 74 2e |mulative| effect.|
|00002310| 0a 0a 60 2d 4e 27 0a 60 | 5e 4e 27 0a 20 20 20 20 |..`-N'.`|^N'. |
|00002320| 20 54 68 65 20 4e 74 68 | 20 70 72 65 76 69 6f 75 | The Nth| previou|
|00002330| 73 20 6c 69 6e 65 2c 20 | 77 68 65 72 65 20 4e 20 |s line, |where N |
|00002340| 69 73 20 61 20 6e 6f 6e | 2d 6e 65 67 61 74 69 76 |is a non|-negativ|
|00002350| 65 20 6e 75 6d 62 65 72 | 2e 0a 0a 60 2b 27 0a 20 |e number|...`+'. |
|00002360| 20 20 20 20 54 68 65 20 | 6e 65 78 74 20 6c 69 6e | The |next lin|
|00002370| 65 2e 20 20 54 68 69 73 | 20 69 73 20 65 71 75 69 |e. This| is equi|
|00002380| 76 61 6c 65 6e 74 20 74 | 6f 20 60 2b 31 27 20 61 |valent t|o `+1' a|
|00002390| 6e 64 20 6d 61 79 20 62 | 65 20 72 65 70 65 61 74 |nd may b|e repeat|
|000023a0| 65 64 20 77 69 74 68 0a | 20 20 20 20 20 63 75 6d |ed with.| cum|
|000023b0| 75 6c 61 74 69 76 65 20 | 65 66 66 65 63 74 2e 0a |ulative |effect..|
|000023c0| 0a 60 2b 4e 27 0a 60 57 | 48 49 54 45 53 50 41 43 |.`+N'.`W|HITESPAC|
|000023d0| 45 20 4e 27 0a 20 20 20 | 20 20 54 68 65 20 4e 74 |E N'. | The Nt|
|000023e0| 68 20 6e 65 78 74 20 6c | 69 6e 65 2c 20 77 68 65 |h next l|ine, whe|
|000023f0| 72 65 20 4e 20 69 73 20 | 61 20 6e 6f 6e 2d 6e 65 |re N is |a non-ne|
|00002400| 67 61 74 69 76 65 20 6e | 75 6d 62 65 72 2e 20 20 |gative n|umber. |
|00002410| 57 68 69 74 65 73 70 61 | 63 65 0a 20 20 20 20 20 |Whitespa|ce. |
|00002420| 66 6f 6c 6c 6f 77 65 64 | 20 62 79 20 61 20 6e 75 |followed| by a nu|
|00002430| 6d 62 65 72 20 4e 20 69 | 73 20 69 6e 74 65 72 70 |mber N i|s interp|
|00002440| 72 65 74 65 64 20 61 73 | 20 60 2b 4e 27 2e 0a 0a |reted as| `+N'...|
|00002450| 60 2c 27 0a 60 25 27 0a | 20 20 20 20 20 54 68 65 |`,'.`%'.| The|
|00002460| 20 66 69 72 73 74 20 74 | 68 72 6f 75 67 68 20 6c | first t|hrough l|
|00002470| 61 73 74 20 6c 69 6e 65 | 73 20 69 6e 20 74 68 65 |ast line|s in the|
|00002480| 20 62 75 66 66 65 72 2e | 20 20 54 68 69 73 20 69 | buffer.| This i|
|00002490| 73 20 65 71 75 69 76 61 | 6c 65 6e 74 20 74 6f 0a |s equiva|lent to.|
|000024a0| 20 20 20 20 20 74 68 65 | 20 61 64 64 72 65 73 73 | the| address|
|000024b0| 20 72 61 6e 67 65 20 60 | 31 2c 24 27 2e 0a 0a 60 | range `|1,$'...`|
|000024c0| 3b 27 0a 20 20 20 20 20 | 54 68 65 20 63 75 72 72 |;'. |The curr|
|000024d0| 65 6e 74 20 74 68 72 6f | 75 67 68 20 6c 61 73 74 |ent thro|ugh last|
|000024e0| 20 6c 69 6e 65 73 20 69 | 6e 20 74 68 65 20 62 75 | lines i|n the bu|
|000024f0| 66 66 65 72 2e 20 20 54 | 68 69 73 20 69 73 20 65 |ffer. T|his is e|
|00002500| 71 75 69 76 61 6c 65 6e | 74 0a 20 20 20 20 20 74 |quivalen|t. t|
|00002510| 6f 20 74 68 65 20 61 64 | 64 72 65 73 73 20 72 61 |o the ad|dress ra|
|00002520| 6e 67 65 20 60 2e 2c 24 | 27 2e 0a 0a 60 2f 52 45 |nge `.,$|'...`/RE|
|00002530| 2f 27 0a 20 20 20 20 20 | 54 68 65 20 6e 65 78 74 |/'. |The next|
|00002540| 20 6c 69 6e 65 20 63 6f | 6e 74 61 69 6e 69 6e 67 | line co|ntaining|
|00002550| 20 74 68 65 20 72 65 67 | 75 6c 61 72 20 65 78 70 | the reg|ular exp|
|00002560| 72 65 73 73 69 6f 6e 20 | 52 45 2e 20 20 54 68 65 |ression |RE. The|
|00002570| 20 73 65 61 72 63 68 0a | 20 20 20 20 20 77 72 61 | search.| wra|
|00002580| 70 73 20 74 6f 20 74 68 | 65 20 62 65 67 69 6e 6e |ps to th|e beginn|
|00002590| 69 6e 67 20 6f 66 20 74 | 68 65 20 62 75 66 66 65 |ing of t|he buffe|
|000025a0| 72 20 61 6e 64 20 63 6f | 6e 74 69 6e 75 65 73 20 |r and co|ntinues |
|000025b0| 64 6f 77 6e 20 74 6f 20 | 74 68 65 0a 20 20 20 20 |down to |the. |
|000025c0| 20 63 75 72 72 65 6e 74 | 20 6c 69 6e 65 2c 20 69 | current| line, i|
|000025d0| 66 20 6e 65 63 65 73 73 | 61 72 79 2e 20 20 60 2f |f necess|ary. `/|
|000025e0| 2f 27 20 72 65 70 65 61 | 74 73 20 74 68 65 20 6c |/' repea|ts the l|
|000025f0| 61 73 74 20 73 65 61 72 | 63 68 2e 0a 0a 60 3f 52 |ast sear|ch...`?R|
|00002600| 45 3f 27 0a 20 20 20 20 | 20 54 68 65 20 70 72 65 |E?'. | The pre|
|00002610| 76 69 6f 75 73 20 6c 69 | 6e 65 20 63 6f 6e 74 61 |vious li|ne conta|
|00002620| 69 6e 69 6e 67 20 74 68 | 65 20 72 65 67 75 6c 61 |ining th|e regula|
|00002630| 72 20 65 78 70 72 65 73 | 73 69 6f 6e 20 52 45 2e |r expres|sion RE.|
|00002640| 20 20 54 68 65 0a 20 20 | 20 20 20 73 65 61 72 63 | The. | searc|
|00002650| 68 20 77 72 61 70 73 20 | 74 6f 20 74 68 65 20 65 |h wraps |to the e|
|00002660| 6e 64 20 6f 66 20 74 68 | 65 20 62 75 66 66 65 72 |nd of th|e buffer|
|00002670| 20 61 6e 64 20 63 6f 6e | 74 69 6e 75 65 73 20 75 | and con|tinues u|
|00002680| 70 20 74 6f 20 74 68 65 | 0a 20 20 20 20 20 63 75 |p to the|. cu|
|00002690| 72 72 65 6e 74 20 6c 69 | 6e 65 2c 20 69 66 20 6e |rrent li|ne, if n|
|000026a0| 65 63 65 73 73 61 72 79 | 2e 20 20 60 3f 3f 27 20 |ecessary|. `??' |
|000026b0| 72 65 70 65 61 74 73 20 | 74 68 65 20 6c 61 73 74 |repeats |the last|
|000026c0| 20 73 65 61 72 63 68 2e | 0a 0a 60 27 4c 43 27 0a | search.|..`'LC'.|
|000026d0| 20 20 20 20 20 54 68 65 | 20 6c 69 6e 65 20 70 72 | The| line pr|
|000026e0| 65 76 69 6f 75 73 6c 79 | 20 6d 61 72 6b 65 64 20 |eviously| marked |
|000026f0| 62 79 20 61 20 60 6b 27 | 20 28 6d 61 72 6b 29 20 |by a `k'| (mark) |
|00002700| 63 6f 6d 6d 61 6e 64 2c | 20 77 68 65 72 65 20 4c |command,| where L|
|00002710| 43 20 69 73 20 61 0a 20 | 20 20 20 20 6c 6f 77 65 |C is a. | lowe|
|00002720| 72 20 63 61 73 65 20 6c | 65 74 74 65 72 2e 0a 0a |r case l|etter...|
|00002730| 1f 0a 46 69 6c 65 3a 20 | 65 64 2e 69 6e 66 6f 2c |..File: |ed.info,|
|00002740| 20 20 4e 6f 64 65 3a 20 | 52 65 67 75 6c 61 72 20 | Node: |Regular |
|00002750| 65 78 70 72 65 73 73 69 | 6f 6e 73 2c 20 20 4e 65 |expressi|ons, Ne|
|00002760| 78 74 3a 20 43 6f 6d 6d | 61 6e 64 73 2c 20 20 50 |xt: Comm|ands, P|
|00002770| 72 65 76 3a 20 4c 69 6e | 65 20 61 64 64 72 65 73 |rev: Lin|e addres|
|00002780| 73 69 6e 67 2c 20 20 55 | 70 3a 20 54 6f 70 0a 0a |sing, U|p: Top..|
|00002790| 52 65 67 75 6c 61 72 20 | 65 78 70 72 65 73 73 69 |Regular |expressi|
|000027a0| 6f 6e 73 0a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |ons.****|********|
|000027b0| 2a 2a 2a 2a 2a 2a 2a 0a | 0a 20 20 20 52 65 67 75 |*******.|. Regu|
|000027c0| 6c 61 72 20 65 78 70 72 | 65 73 73 69 6f 6e 73 20 |lar expr|essions |
|000027d0| 61 72 65 20 70 61 74 74 | 65 72 6e 73 20 75 73 65 |are patt|erns use|
|000027e0| 64 20 69 6e 20 73 65 6c | 65 63 74 69 6e 67 20 74 |d in sel|ecting t|
|000027f0| 65 78 74 2e 20 20 46 6f | 72 0a 65 78 61 6d 70 6c |ext. Fo|r.exampl|
|00002800| 65 2c 20 74 68 65 20 60 | 65 64 27 20 63 6f 6d 6d |e, the `|ed' comm|
|00002810| 61 6e 64 0a 0a 20 20 20 | 20 20 67 2f 53 54 52 49 |and.. | g/STRI|
|00002820| 4e 47 2f 0a 0a 70 72 69 | 6e 74 73 20 61 6c 6c 20 |NG/..pri|nts all |
|00002830| 6c 69 6e 65 73 20 63 6f | 6e 74 61 69 6e 69 6e 67 |lines co|ntaining|
|00002840| 20 53 54 52 49 4e 47 2e | 20 20 52 65 67 75 6c 61 | STRING.| Regula|
|00002850| 72 20 65 78 70 72 65 73 | 73 69 6f 6e 73 20 61 72 |r expres|sions ar|
|00002860| 65 20 61 6c 73 6f 20 75 | 73 65 64 0a 62 79 20 74 |e also u|sed.by t|
|00002870| 68 65 20 60 73 27 20 63 | 6f 6d 6d 61 6e 64 20 66 |he `s' c|ommand f|
|00002880| 6f 72 20 73 65 6c 65 63 | 74 69 6e 67 20 6f 6c 64 |or selec|ting old|
|00002890| 20 74 65 78 74 20 74 6f | 20 62 65 20 72 65 70 6c | text to| be repl|
|000028a0| 61 63 65 64 20 77 69 74 | 68 20 6e 65 77 2e 0a 0a |aced wit|h new...|
|000028b0| 20 20 20 49 6e 20 61 64 | 64 69 74 69 6f 6e 20 74 | In ad|dition t|
|000028c0| 6f 20 61 20 73 70 65 63 | 69 66 79 69 6e 67 20 73 |o a spec|ifying s|
|000028d0| 74 72 69 6e 67 20 6c 69 | 74 65 72 61 6c 73 2c 20 |tring li|terals, |
|000028e0| 72 65 67 75 6c 61 72 20 | 65 78 70 72 65 73 73 69 |regular |expressi|
|000028f0| 6f 6e 73 20 63 61 6e 0a | 72 65 70 72 65 73 65 6e |ons can.|represen|
|00002900| 74 20 63 6c 61 73 73 65 | 73 20 6f 66 20 73 74 72 |t classe|s of str|
|00002910| 69 6e 67 73 2e 20 20 53 | 74 72 69 6e 67 73 20 74 |ings. S|trings t|
|00002920| 68 75 73 20 72 65 70 72 | 65 73 65 6e 74 65 64 20 |hus repr|esented |
|00002930| 61 72 65 20 73 61 69 64 | 20 74 6f 20 62 65 0a 6d |are said| to be.m|
|00002940| 61 74 63 68 65 64 20 62 | 79 20 74 68 65 20 63 6f |atched b|y the co|
|00002950| 72 72 65 73 70 6f 6e 64 | 69 6e 67 20 72 65 67 75 |rrespond|ing regu|
|00002960| 6c 61 72 20 65 78 70 72 | 65 73 73 69 6f 6e 2e 20 |lar expr|ession. |
|00002970| 20 49 66 20 69 74 20 69 | 73 20 70 6f 73 73 69 62 | If it i|s possib|
|00002980| 6c 65 20 66 6f 72 0a 61 | 20 72 65 67 75 6c 61 72 |le for.a| regular|
|00002990| 20 65 78 70 72 65 73 73 | 69 6f 6e 20 74 6f 20 6d | express|ion to m|
|000029a0| 61 74 63 68 20 73 65 76 | 65 72 61 6c 20 73 74 72 |atch sev|eral str|
|000029b0| 69 6e 67 73 20 69 6e 20 | 61 20 6c 69 6e 65 2c 20 |ings in |a line, |
|000029c0| 74 68 65 6e 20 74 68 65 | 0a 6c 65 66 74 2d 6d 6f |then the|.left-mo|
|000029d0| 73 74 20 6c 6f 6e 67 65 | 73 74 20 6d 61 74 63 68 |st longe|st match|
|000029e0| 20 69 73 20 74 68 65 20 | 6f 6e 65 20 73 65 6c 65 | is the |one sele|
|000029f0| 63 74 65 64 2e 0a 0a 20 | 20 20 54 68 65 20 66 6f |cted... | The fo|
|00002a00| 6c 6c 6f 77 69 6e 67 20 | 73 79 6d 62 6f 6c 73 20 |llowing |symbols |
|00002a10| 61 72 65 20 75 73 65 64 | 20 69 6e 20 63 6f 6e 73 |are used| in cons|
|00002a20| 74 72 75 63 74 69 6e 67 | 20 72 65 67 75 6c 61 72 |tructing| regular|
|00002a30| 20 65 78 70 72 65 73 73 | 69 6f 6e 73 3a 0a 0a 60 | express|ions:..`|
|00002a40| 43 27 0a 20 20 20 20 20 | 41 6e 79 20 63 68 61 72 |C'. |Any char|
|00002a50| 61 63 74 65 72 20 43 20 | 6e 6f 74 20 6c 69 73 74 |acter C |not list|
|00002a60| 65 64 20 62 65 6c 6f 77 | 2c 20 69 6e 63 6c 75 64 |ed below|, includ|
|00002a70| 69 6e 67 20 60 7b 27 2c | 20 60 7d 27 2c 20 60 28 |ing `{',| `}', `(|
|00002a80| 27 2c 20 60 29 27 2c 0a | 20 20 20 20 20 60 3c 27 |', `)',.| `<'|
|00002a90| 20 61 6e 64 20 60 3e 27 | 2c 20 6d 61 74 63 68 65 | and `>'|, matche|
|00002aa0| 73 20 69 74 73 65 6c 66 | 2e 0a 0a 60 5c 43 27 0a |s itself|...`\C'.|
|00002ab0| 20 20 20 20 20 41 6e 79 | 20 62 61 63 6b 73 6c 61 | Any| backsla|
|00002ac0| 73 68 2d 65 73 63 61 70 | 65 64 20 63 68 61 72 61 |sh-escap|ed chara|
|00002ad0| 63 74 65 72 20 43 2c 20 | 65 78 63 65 70 74 20 66 |cter C, |except f|
|00002ae0| 6f 72 20 60 7b 27 2c 20 | 60 60 7d 27 2c 20 60 28 |or `{', |``}', `(|
|00002af0| 27 2c 20 60 29 27 2c 0a | 20 20 20 20 20 60 3c 27 |', `)',.| `<'|
|00002b00| 20 61 6e 64 20 60 3e 27 | 2c 20 6d 61 74 63 68 65 | and `>'|, matche|
|00002b10| 73 20 69 74 73 65 6c 66 | 2e 0a 0a 60 2e 27 0a 20 |s itself|...`.'. |
|00002b20| 20 20 20 20 4d 61 74 63 | 68 65 73 20 61 6e 79 20 | Matc|hes any |
|00002b30| 73 69 6e 67 6c 65 20 63 | 68 61 72 61 63 74 65 72 |single c|haracter|
|00002b40| 2e 0a 0a 60 5b 43 48 41 | 52 2d 43 4c 41 53 53 5d |...`[CHA|R-CLASS]|
|00002b50| 27 0a 20 20 20 20 20 4d | 61 74 63 68 65 73 20 61 |'. M|atches a|
|00002b60| 6e 79 20 73 69 6e 67 6c | 65 20 63 68 61 72 61 63 |ny singl|e charac|
|00002b70| 74 65 72 20 69 6e 20 43 | 48 41 52 2d 43 4c 41 53 |ter in C|HAR-CLAS|
|00002b80| 53 2e 20 20 54 6f 20 69 | 6e 63 6c 75 64 65 20 61 |S. To i|nclude a|
|00002b90| 20 60 5d 27 20 69 6e 0a | 20 20 20 20 20 43 48 41 | `]' in.| CHA|
|00002ba0| 52 2d 43 4c 41 53 53 2c | 20 69 74 20 6d 75 73 74 |R-CLASS,| it must|
|00002bb0| 20 62 65 20 74 68 65 20 | 66 69 72 73 74 20 63 68 | be the |first ch|
|00002bc0| 61 72 61 63 74 65 72 2e | 20 20 41 20 72 61 6e 67 |aracter.| A rang|
|00002bd0| 65 20 6f 66 20 63 68 61 | 72 61 63 74 65 72 73 0a |e of cha|racters.|
|00002be0| 20 20 20 20 20 6d 61 79 | 20 62 65 20 73 70 65 63 | may| be spec|
|00002bf0| 69 66 69 65 64 20 62 79 | 20 73 65 70 61 72 61 74 |ified by| separat|
|00002c00| 69 6e 67 20 74 68 65 20 | 65 6e 64 20 63 68 61 72 |ing the |end char|
|00002c10| 61 63 74 65 72 73 20 6f | 66 20 74 68 65 20 72 61 |acters o|f the ra|
|00002c20| 6e 67 65 0a 20 20 20 20 | 20 77 69 74 68 20 61 20 |nge. | with a |
|00002c30| 60 2d 27 2c 20 65 2e 67 | 2e 2c 20 60 61 2d 7a 27 |`-', e.g|., `a-z'|
|00002c40| 20 73 70 65 63 69 66 69 | 65 73 20 74 68 65 20 6c | specifi|es the l|
|00002c50| 6f 77 65 72 20 63 61 73 | 65 20 63 68 61 72 61 63 |ower cas|e charac|
|00002c60| 74 65 72 73 2e 20 20 54 | 68 65 0a 20 20 20 20 20 |ters. T|he. |
|00002c70| 66 6f 6c 6c 6f 77 69 6e | 67 20 6c 69 74 65 72 61 |followin|g litera|
|00002c80| 6c 20 65 78 70 72 65 73 | 73 69 6f 6e 73 20 63 61 |l expres|sions ca|
|00002c90| 6e 20 61 6c 73 6f 20 62 | 65 20 75 73 65 64 20 69 |n also b|e used i|
|00002ca0| 6e 20 43 48 41 52 2d 43 | 4c 41 53 53 20 74 6f 0a |n CHAR-C|LASS to.|
|00002cb0| 20 20 20 20 20 73 70 65 | 63 69 66 79 20 73 65 74 | spe|cify set|
|00002cc0| 73 20 6f 66 20 63 68 61 | 72 61 63 74 65 72 73 3a |s of cha|racters:|
|00002cd0| 0a 0a 20 20 20 20 20 20 | 20 20 20 20 5b 3a 61 6c |.. | [:al|
|00002ce0| 6e 75 6d 3a 5d 20 5b 3a | 63 6e 74 72 6c 3a 5d 20 |num:] [:|cntrl:] |
|00002cf0| 5b 3a 6c 6f 77 65 72 3a | 5d 20 5b 3a 73 70 61 63 |[:lower:|] [:spac|
|00002d00| 65 3a 5d 0a 20 20 20 20 | 20 20 20 20 20 20 5b 3a |e:]. | [:|
|00002d10| 61 6c 70 68 61 3a 5d 20 | 5b 3a 64 69 67 69 74 3a |alpha:] |[:digit:|
|00002d20| 5d 20 5b 3a 70 72 69 6e | 74 3a 5d 20 5b 3a 75 70 |] [:prin|t:] [:up|
|00002d30| 70 65 72 3a 5d 0a 20 20 | 20 20 20 20 20 20 20 20 |per:]. | |
|00002d40| 5b 3a 62 6c 61 6e 6b 3a | 5d 20 5b 3a 67 72 61 70 |[:blank:|] [:grap|
|00002d50| 68 3a 5d 20 5b 3a 70 75 | 6e 63 74 3a 5d 20 5b 3a |h:] [:pu|nct:] [:|
|00002d60| 78 64 69 67 69 74 3a 5d | 0a 0a 20 20 20 20 20 49 |xdigit:]|.. I|
|00002d70| 66 20 60 2d 27 20 61 70 | 70 65 61 72 73 20 61 73 |f `-' ap|pears as|
|00002d80| 20 74 68 65 20 66 69 72 | 73 74 20 6f 72 20 6c 61 | the fir|st or la|
|00002d90| 73 74 20 63 68 61 72 61 | 63 74 65 72 20 6f 66 20 |st chara|cter of |
|00002da0| 43 48 41 52 2d 43 4c 41 | 53 53 2c 20 74 68 65 6e |CHAR-CLA|SS, then|
|00002db0| 0a 20 20 20 20 20 69 74 | 20 6d 61 74 63 68 65 73 |. it| matches|
|00002dc0| 20 69 74 73 65 6c 66 2e | 20 20 41 6c 6c 20 6f 74 | itself.| All ot|
|00002dd0| 68 65 72 20 63 68 61 72 | 61 63 74 65 72 73 20 69 |her char|acters i|
|00002de0| 6e 20 43 48 41 52 2d 43 | 4c 41 53 53 20 6d 61 74 |n CHAR-C|LASS mat|
|00002df0| 63 68 0a 20 20 20 20 20 | 74 68 65 6d 73 65 6c 76 |ch. |themselv|
|00002e00| 65 73 2e 0a 0a 20 20 20 | 20 20 50 61 74 74 65 72 |es... | Patter|
|00002e10| 6e 73 20 69 6e 20 43 48 | 41 52 2d 43 4c 41 53 53 |ns in CH|AR-CLASS|
|00002e20| 20 6f 66 20 74 68 65 20 | 66 6f 72 6d 3a 0a 20 20 | of the |form:. |
|00002e30| 20 20 20 20 20 20 20 20 | 5b 2e 43 4f 4c 2d 45 4c | |[.COL-EL|
|00002e40| 4d 2e 5d 0a 20 20 20 20 | 20 20 20 20 20 20 5b 3d |M.]. | [=|
|00002e50| 43 4f 4c 2d 45 4c 4d 3d | 5d 0a 0a 20 20 20 20 20 |COL-ELM=|].. |
|00002e60| 77 68 65 72 65 20 43 4f | 4c 2d 45 4c 4d 20 69 73 |where CO|L-ELM is|
|00002e70| 20 61 20 22 63 6f 6c 6c | 61 74 69 6e 67 20 65 6c | a "coll|ating el|
|00002e80| 65 6d 65 6e 74 22 20 61 | 72 65 20 69 6e 74 65 72 |ement" a|re inter|
|00002e90| 70 72 65 74 65 64 20 61 | 63 63 6f 72 64 69 6e 67 |preted a|ccording|
|00002ea0| 0a 20 20 20 20 20 74 6f | 20 60 6c 6f 63 61 6c 65 |. to| `locale|
|00002eb0| 20 28 35 29 27 20 28 6e | 6f 74 20 63 75 72 72 65 | (5)' (n|ot curre|
|00002ec0| 6e 74 6c 79 20 73 75 70 | 70 6f 72 74 65 64 29 2e |ntly sup|ported).|
|00002ed0| 20 20 53 65 65 20 60 72 | 65 67 65 78 20 28 33 29 | See `r|egex (3)|
|00002ee0| 27 20 66 6f 72 20 61 6e | 0a 20 20 20 20 20 65 78 |' for an|. ex|
|00002ef0| 70 6c 61 6e 61 74 69 6f | 6e 20 6f 66 20 74 68 65 |planatio|n of the|
|00002f00| 73 65 20 63 6f 6e 73 74 | 72 75 63 74 73 2e 0a 0a |se const|ructs...|
|00002f10| 60 5b 5e 43 48 41 52 2d | 43 4c 41 53 53 5d 27 0a |`[^CHAR-|CLASS]'.|
|00002f20| 20 20 20 20 20 4d 61 74 | 63 68 65 73 20 61 6e 79 | Mat|ches any|
|00002f30| 20 73 69 6e 67 6c 65 20 | 63 68 61 72 61 63 74 65 | single |characte|
|00002f40| 72 2c 20 6f 74 68 65 72 | 20 74 68 61 6e 20 6e 65 |r, other| than ne|
|00002f50| 77 6c 69 6e 65 2c 20 6e | 6f 74 20 69 6e 0a 20 20 |wline, n|ot in. |
|00002f60| 20 20 20 43 48 41 52 2d | 43 4c 41 53 53 2e 20 20 | CHAR-|CLASS. |
|00002f70| 43 48 41 52 2d 43 4c 41 | 53 53 20 69 73 20 64 65 |CHAR-CLA|SS is de|
|00002f80| 66 69 6e 65 64 20 61 73 | 20 61 62 6f 76 65 2e 0a |fined as| above..|
|00002f90| 0a 60 5e 27 0a 20 20 20 | 20 20 49 66 20 60 5e 27 |.`^'. | If `^'|
|00002fa0| 20 69 73 20 74 68 65 20 | 66 69 72 73 74 20 63 68 | is the |first ch|
|00002fb0| 61 72 61 63 74 65 72 20 | 6f 66 20 61 20 72 65 67 |aracter |of a reg|
|00002fc0| 75 6c 61 72 20 65 78 70 | 72 65 73 73 69 6f 6e 2c |ular exp|ression,|
|00002fd0| 20 74 68 65 6e 20 69 74 | 0a 20 20 20 20 20 61 6e | then it|. an|
|00002fe0| 63 68 6f 72 73 20 74 68 | 65 20 72 65 67 75 6c 61 |chors th|e regula|
|00002ff0| 72 20 65 78 70 72 65 73 | 73 69 6f 6e 20 74 6f 20 |r expres|sion to |
|00003000| 74 68 65 20 62 65 67 69 | 6e 6e 69 6e 67 20 6f 66 |the begi|nning of|
|00003010| 20 61 20 6c 69 6e 65 2e | 0a 20 20 20 20 20 4f 74 | a line.|. Ot|
|00003020| 68 65 72 77 69 73 65 2c | 20 69 74 20 6d 61 74 63 |herwise,| it matc|
|00003030| 68 65 73 20 69 74 73 65 | 6c 66 2e 0a 0a 60 24 27 |hes itse|lf...`$'|
|00003040| 0a 20 20 20 20 20 49 66 | 20 60 24 27 20 69 73 20 |. If| `$' is |
|00003050| 74 68 65 20 6c 61 73 74 | 20 63 68 61 72 61 63 74 |the last| charact|
|00003060| 65 72 20 6f 66 20 61 20 | 72 65 67 75 6c 61 72 20 |er of a |regular |
|00003070| 65 78 70 72 65 73 73 69 | 6f 6e 2c 20 69 74 20 61 |expressi|on, it a|
|00003080| 6e 63 68 6f 72 73 0a 20 | 20 20 20 20 74 68 65 20 |nchors. | the |
|00003090| 72 65 67 75 6c 61 72 20 | 65 78 70 72 65 73 73 69 |regular |expressi|
|000030a0| 6f 6e 20 74 6f 20 74 68 | 65 20 65 6e 64 20 6f 66 |on to th|e end of|
|000030b0| 20 61 20 6c 69 6e 65 2e | 20 20 4f 74 68 65 72 77 | a line.| Otherw|
|000030c0| 69 73 65 2c 20 69 74 20 | 6d 61 74 63 68 65 73 0a |ise, it |matches.|
|000030d0| 20 20 20 20 20 69 74 73 | 65 6c 66 2e 0a 0a 60 5c | its|elf...`\|
|000030e0| 3c 27 0a 20 20 20 20 20 | 41 6e 63 68 6f 72 73 20 |<'. |Anchors |
|000030f0| 74 68 65 20 73 69 6e 67 | 6c 65 20 63 68 61 72 61 |the sing|le chara|
|00003100| 63 74 65 72 20 72 65 67 | 75 6c 61 72 20 65 78 70 |cter reg|ular exp|
|00003110| 72 65 73 73 69 6f 6e 20 | 6f 72 20 73 75 62 65 78 |ression |or subex|
|00003120| 70 72 65 73 73 69 6f 6e | 0a 20 20 20 20 20 69 6d |pression|. im|
|00003130| 6d 65 64 69 61 74 65 6c | 79 20 66 6f 6c 6c 6f 77 |mediatel|y follow|
|00003140| 69 6e 67 20 69 74 20 74 | 6f 20 74 68 65 20 62 65 |ing it t|o the be|
|00003150| 67 69 6e 6e 69 6e 67 20 | 6f 66 20 61 20 77 6f 72 |ginning |of a wor|
|00003160| 64 2e 20 20 28 54 68 69 | 73 20 6d 61 79 0a 20 20 |d. (Thi|s may. |
|00003170| 20 20 20 6e 6f 74 20 62 | 65 20 61 76 61 69 6c 61 | not b|e availa|
|00003180| 62 6c 65 29 0a 0a 60 5c | 3e 27 0a 20 20 20 20 20 |ble)..`\|>'. |
|00003190| 41 6e 63 68 6f 72 73 20 | 74 68 65 20 73 69 6e 67 |Anchors |the sing|
|000031a0| 6c 65 20 63 68 61 72 61 | 63 74 65 72 20 72 65 67 |le chara|cter reg|
|000031b0| 75 6c 61 72 20 65 78 70 | 72 65 73 73 69 6f 6e 20 |ular exp|ression |
|000031c0| 6f 72 20 73 75 62 65 78 | 70 72 65 73 73 69 6f 6e |or subex|pression|
|000031d0| 0a 20 20 20 20 20 69 6d | 6d 65 64 69 61 74 65 6c |. im|mediatel|
|000031e0| 79 20 66 6f 6c 6c 6f 77 | 69 6e 67 20 69 74 20 74 |y follow|ing it t|
|000031f0| 6f 20 74 68 65 20 65 6e | 64 20 6f 66 20 61 20 77 |o the en|d of a w|
|00003200| 6f 72 64 2e 20 20 28 54 | 68 69 73 20 6d 61 79 20 |ord. (T|his may |
|00003210| 6e 6f 74 20 62 65 0a 20 | 20 20 20 20 61 76 61 69 |not be. | avai|
|00003220| 6c 61 62 6c 65 29 0a 0a | 60 5c 28 52 45 5c 29 27 |lable)..|`\(RE\)'|
|00003230| 0a 20 20 20 20 20 44 65 | 66 69 6e 65 73 20 61 20 |. De|fines a |
|00003240| 73 75 62 65 78 70 72 65 | 73 73 69 6f 6e 20 52 45 |subexpre|ssion RE|
|00003250| 2e 20 20 53 75 62 65 78 | 70 72 65 73 73 69 6f 6e |. Subex|pression|
|00003260| 73 20 6d 61 79 20 62 65 | 20 6e 65 73 74 65 64 2e |s may be| nested.|
|00003270| 20 20 41 0a 20 20 20 20 | 20 73 75 62 73 65 71 75 | A. | subsequ|
|00003280| 65 6e 74 20 62 61 63 6b | 72 65 66 65 72 65 6e 63 |ent back|referenc|
|00003290| 65 20 6f 66 20 74 68 65 | 20 66 6f 72 6d 20 60 5c |e of the| form `\|
|000032a0| 4e 27 2c 20 77 68 65 72 | 65 20 4e 20 69 73 20 61 |N', wher|e N is a|
|000032b0| 20 6e 75 6d 62 65 72 20 | 69 6e 0a 20 20 20 20 20 | number |in. |
|000032c0| 74 68 65 20 72 61 6e 67 | 65 20 5b 31 2c 39 5d 2c |the rang|e [1,9],|
|000032d0| 20 65 78 70 61 6e 64 73 | 20 74 6f 20 74 68 65 20 | expands| to the |
|000032e0| 74 65 78 74 20 6d 61 74 | 63 68 65 64 20 62 79 20 |text mat|ched by |
|000032f0| 74 68 65 20 4e 74 68 0a | 20 20 20 20 20 73 75 62 |the Nth.| sub|
|00003300| 65 78 70 72 65 73 73 69 | 6f 6e 2e 20 20 46 6f 72 |expressi|on. For|
|00003310| 20 65 78 61 6d 70 6c 65 | 2c 20 74 68 65 20 72 65 | example|, the re|
|00003320| 67 75 6c 61 72 20 65 78 | 70 72 65 73 73 69 6f 6e |gular ex|pression|
|00003330| 20 60 5c 28 5b 61 62 5d | 5c 29 5c 31 27 0a 20 20 | `\([ab]|\)\1'. |
|00003340| 20 20 20 6d 61 74 63 68 | 65 73 20 74 68 65 20 73 | match|es the s|
|00003350| 74 72 69 6e 67 73 20 60 | 61 61 27 20 61 6e 64 20 |trings `|aa' and |
|00003360| 60 62 62 27 20 28 61 6e | 64 20 6f 6e 6c 79 20 74 |`bb' (an|d only t|
|00003370| 68 65 73 65 29 2e 0a 20 | 20 20 20 20 53 75 62 65 |hese).. | Sube|
|00003380| 78 70 72 65 73 73 69 6f | 6e 73 20 61 72 65 20 6f |xpressio|ns are o|
|00003390| 72 64 65 72 65 64 20 72 | 65 6c 61 74 69 76 65 20 |rdered r|elative |
|000033a0| 74 6f 20 74 68 65 69 72 | 20 6c 65 66 74 20 64 65 |to their| left de|
|000033b0| 6c 69 6d 69 74 65 72 2e | 0a 0a 60 2a 27 0a 20 20 |limiter.|..`*'. |
|000033c0| 20 20 20 4d 61 74 63 68 | 65 73 20 74 68 65 20 73 | Match|es the s|
|000033d0| 69 6e 67 6c 65 20 63 68 | 61 72 61 63 74 65 72 20 |ingle ch|aracter |
|000033e0| 72 65 67 75 6c 61 72 20 | 65 78 70 72 65 73 73 69 |regular |expressi|
|000033f0| 6f 6e 20 6f 72 20 73 75 | 62 65 78 70 72 65 73 73 |on or su|bexpress|
|00003400| 69 6f 6e 0a 20 20 20 20 | 20 69 6d 6d 65 64 69 61 |ion. | immedia|
|00003410| 74 65 6c 79 20 70 72 65 | 63 65 64 69 6e 67 20 69 |tely pre|ceding i|
|00003420| 74 20 7a 65 72 6f 20 6f | 72 20 6d 6f 72 65 20 74 |t zero o|r more t|
|00003430| 69 6d 65 73 2e 20 20 49 | 66 20 60 2a 27 20 69 73 |imes. I|f `*' is|
|00003440| 20 74 68 65 20 66 69 72 | 73 74 0a 20 20 20 20 20 | the fir|st. |
|00003450| 63 68 61 72 61 63 74 65 | 72 20 6f 66 20 61 20 72 |characte|r of a r|
|00003460| 65 67 75 6c 61 72 20 65 | 78 70 72 65 73 73 69 6f |egular e|xpressio|
|00003470| 6e 20 6f 72 20 73 75 62 | 65 78 70 72 65 73 73 69 |n or sub|expressi|
|00003480| 6f 6e 2c 20 74 68 65 6e | 20 69 74 20 6d 61 74 63 |on, then| it matc|
|00003490| 68 65 73 0a 20 20 20 20 | 20 69 74 73 65 6c 66 2e |hes. | itself.|
|000034a0| 20 20 54 68 65 20 60 2a | 27 20 6f 70 65 72 61 74 | The `*|' operat|
|000034b0| 6f 72 20 73 6f 6d 65 74 | 69 6d 65 73 20 79 69 65 |or somet|imes yie|
|000034c0| 6c 64 73 20 75 6e 65 78 | 70 65 63 74 65 64 20 72 |lds unex|pected r|
|000034d0| 65 73 75 6c 74 73 2e 20 | 20 46 6f 72 0a 20 20 20 |esults. | For. |
|000034e0| 20 20 65 78 61 6d 70 6c | 65 2c 20 74 68 65 20 72 | exampl|e, the r|
|000034f0| 65 67 75 6c 61 72 20 65 | 78 70 72 65 73 73 69 6f |egular e|xpressio|
|00003500| 6e 20 60 62 2a 27 20 6d | 61 74 63 68 65 73 20 74 |n `b*' m|atches t|
|00003510| 68 65 20 62 65 67 69 6e | 6e 69 6e 67 20 6f 66 20 |he begin|ning of |
|00003520| 74 68 65 0a 20 20 20 20 | 20 73 74 72 69 6e 67 20 |the. | string |
|00003530| 60 61 62 62 62 27 20 28 | 61 73 20 6f 70 70 6f 73 |`abbb' (|as oppos|
|00003540| 65 64 20 74 6f 20 74 68 | 65 20 73 75 62 73 74 72 |ed to th|e substr|
|00003550| 69 6e 67 20 60 62 62 62 | 27 29 2c 20 73 69 6e 63 |ing `bbb|'), sinc|
|00003560| 65 20 61 20 6e 75 6c 6c | 0a 20 20 20 20 20 6d 61 |e a null|. ma|
|00003570| 74 63 68 20 69 73 20 74 | 68 65 20 6f 6e 6c 79 20 |tch is t|he only |
|00003580| 6c 65 66 74 2d 6d 6f 73 | 74 20 6d 61 74 63 68 2e |left-mos|t match.|
|00003590| 0a 0a 60 7b 4e 2c 4d 7d | 27 0a 60 7b 4e 2c 7d 27 |..`{N,M}|'.`{N,}'|
|000035a0| 0a 60 7b 4e 7d 27 0a 20 | 20 20 20 20 4d 61 74 63 |.`{N}'. | Matc|
|000035b0| 68 65 73 20 74 68 65 20 | 73 69 6e 67 6c 65 20 63 |hes the |single c|
|000035c0| 68 61 72 61 63 74 65 72 | 20 72 65 67 75 6c 61 72 |haracter| regular|
|000035d0| 20 65 78 70 72 65 73 73 | 69 6f 6e 20 6f 72 20 73 | express|ion or s|
|000035e0| 75 62 65 78 70 72 65 73 | 73 69 6f 6e 0a 20 20 20 |ubexpres|sion. |
|000035f0| 20 20 69 6d 6d 65 64 69 | 61 74 65 6c 79 20 70 72 | immedi|ately pr|
|00003600| 65 63 65 64 69 6e 67 20 | 69 74 20 61 74 20 6c 65 |eceding |it at le|
|00003610| 61 73 74 20 4e 20 61 6e | 64 20 61 74 20 6d 6f 73 |ast N an|d at mos|
|00003620| 74 20 4d 20 74 69 6d 65 | 73 2e 20 20 49 66 20 4d |t M time|s. If M|
|00003630| 20 69 73 0a 20 20 20 20 | 20 6f 6d 69 74 74 65 64 | is. | omitted|
|00003640| 2c 20 74 68 65 6e 20 69 | 74 20 6d 61 74 63 68 65 |, then i|t matche|
|00003650| 73 20 61 74 20 6c 65 61 | 73 74 20 4e 20 74 69 6d |s at lea|st N tim|
|00003660| 65 73 2e 20 20 49 66 20 | 74 68 65 20 63 6f 6d 6d |es. If |the comm|
|00003670| 61 20 69 73 20 61 6c 73 | 6f 0a 20 20 20 20 20 6f |a is als|o. o|
|00003680| 6d 69 74 74 65 64 2c 20 | 74 68 65 6e 20 69 74 20 |mitted, |then it |
|00003690| 6d 61 74 63 68 65 73 20 | 65 78 61 63 74 6c 79 20 |matches |exactly |
|000036a0| 4e 20 74 69 6d 65 73 2e | 0a 0a 20 20 20 41 64 64 |N times.|.. Add|
|000036b0| 69 74 69 6f 6e 61 6c 20 | 72 65 67 75 6c 61 72 20 |itional |regular |
|000036c0| 65 78 70 72 65 73 73 69 | 6f 6e 20 6f 70 65 72 61 |expressi|on opera|
|000036d0| 74 6f 72 73 20 6d 61 79 | 20 62 65 20 64 65 66 69 |tors may| be defi|
|000036e0| 6e 65 64 20 64 65 70 65 | 6e 64 69 6e 67 20 6f 6e |ned depe|nding on|
|000036f0| 0a 74 68 65 20 70 61 72 | 74 69 63 75 6c 61 72 20 |.the par|ticular |
|00003700| 60 72 65 67 65 78 20 28 | 33 29 27 20 69 6d 70 6c |`regex (|3)' impl|
|00003710| 65 6d 65 6e 74 61 74 69 | 6f 6e 2e 0a 0a 1f 0a 46 |ementati|on.....F|
|00003720| 69 6c 65 3a 20 65 64 2e | 69 6e 66 6f 2c 20 20 4e |ile: ed.|info, N|
|00003730| 6f 64 65 3a 20 43 6f 6d | 6d 61 6e 64 73 2c 20 20 |ode: Com|mands, |
|00003740| 4e 65 78 74 3a 20 4c 69 | 6d 69 74 61 74 69 6f 6e |Next: Li|mitation|
|00003750| 73 2c 20 20 50 72 65 76 | 3a 20 52 65 67 75 6c 61 |s, Prev|: Regula|
|00003760| 72 20 65 78 70 72 65 73 | 73 69 6f 6e 73 2c 20 20 |r expres|sions, |
|00003770| 55 70 3a 20 54 6f 70 0a | 0a 43 6f 6d 6d 61 6e 64 |Up: Top.|.Command|
|00003780| 73 0a 2a 2a 2a 2a 2a 2a | 2a 2a 0a 0a 20 20 20 41 |s.******|**.. A|
|00003790| 6c 6c 20 60 65 64 27 20 | 63 6f 6d 6d 61 6e 64 73 |ll `ed' |commands|
|000037a0| 20 61 72 65 20 73 69 6e | 67 6c 65 20 63 68 61 72 | are sin|gle char|
|000037b0| 61 63 74 65 72 73 2c 20 | 74 68 6f 75 67 68 20 73 |acters, |though s|
|000037c0| 6f 6d 65 20 72 65 71 75 | 69 72 65 0a 61 64 64 69 |ome requ|ire.addi|
|000037d0| 74 6f 6e 61 6c 20 70 61 | 72 61 6d 65 74 65 72 73 |tonal pa|rameters|
|000037e0| 2e 20 20 49 66 20 61 20 | 63 6f 6d 6d 61 6e 64 27 |. If a |command'|
|000037f0| 73 20 70 61 72 61 6d 65 | 74 65 72 73 20 65 78 74 |s parame|ters ext|
|00003800| 65 6e 64 20 6f 76 65 72 | 20 73 65 76 65 72 61 6c |end over| several|
|00003810| 0a 6c 69 6e 65 73 2c 20 | 74 68 65 6e 20 65 61 63 |.lines, |then eac|
|00003820| 68 20 6c 69 6e 65 20 65 | 78 63 65 70 74 20 66 6f |h line e|xcept fo|
|00003830| 72 20 74 68 65 20 6c 61 | 73 74 20 6d 75 73 74 20 |r the la|st must |
|00003840| 62 65 20 74 65 72 6d 69 | 6e 61 74 65 64 20 77 69 |be termi|nated wi|
|00003850| 74 68 20 61 0a 62 61 63 | 6b 73 6c 61 73 68 20 28 |th a.bac|kslash (|
|00003860| 60 5c 27 29 2e 0a 0a 20 | 20 20 49 6e 20 67 65 6e |`\')... | In gen|
|00003870| 65 72 61 6c 2c 20 61 74 | 20 6d 6f 73 74 20 6f 6e |eral, at| most on|
|00003880| 65 20 63 6f 6d 6d 61 6e | 64 20 69 73 20 61 6c 6c |e comman|d is all|
|00003890| 6f 77 65 64 20 70 65 72 | 20 6c 69 6e 65 2e 20 20 |owed per| line. |
|000038a0| 48 6f 77 65 76 65 72 2c | 20 6d 6f 73 74 0a 63 6f |However,| most.co|
|000038b0| 6d 6d 61 6e 64 73 20 61 | 63 63 65 70 74 20 61 20 |mmands a|ccept a |
|000038c0| 70 72 69 6e 74 20 73 75 | 66 66 69 78 2c 20 77 68 |print su|ffix, wh|
|000038d0| 69 63 68 20 69 73 20 61 | 6e 79 20 6f 66 20 60 70 |ich is a|ny of `p|
|000038e0| 27 20 28 70 72 69 6e 74 | 29 2c 20 60 6c 27 0a 28 |' (print|), `l'.(|
|000038f0| 6c 69 73 74 29 2c 20 6f | 72 20 60 6e 27 20 28 65 |list), o|r `n' (e|
|00003900| 6e 75 6d 65 72 61 74 65 | 29 2c 20 74 6f 20 70 72 |numerate|), to pr|
|00003910| 69 6e 74 20 74 68 65 20 | 6c 61 73 74 20 6c 69 6e |int the |last lin|
|00003920| 65 20 61 66 66 65 63 74 | 65 64 20 62 79 20 74 68 |e affect|ed by th|
|00003930| 65 0a 63 6f 6d 6d 61 6e | 64 2e 0a 0a 20 20 20 41 |e.comman|d... A|
|00003940| 6e 20 69 6e 74 65 72 72 | 75 70 74 20 28 74 79 70 |n interr|upt (typ|
|00003950| 69 63 61 6c 6c 79 20 5e | 43 29 20 68 61 73 20 74 |ically ^|C) has t|
|00003960| 68 65 20 65 66 66 65 63 | 74 20 6f 66 20 61 62 6f |he effec|t of abo|
|00003970| 72 74 69 6e 67 20 74 68 | 65 20 63 75 72 72 65 6e |rting th|e curren|
|00003980| 74 0a 63 6f 6d 6d 61 6e | 64 20 61 6e 64 20 72 65 |t.comman|d and re|
|00003990| 74 75 72 6e 69 6e 67 20 | 74 68 65 20 65 64 69 74 |turning |the edit|
|000039a0| 6f 72 20 74 6f 20 63 6f | 6d 6d 61 6e 64 20 6d 6f |or to co|mmand mo|
|000039b0| 64 65 2e 0a 0a 20 20 20 | 60 65 64 27 20 72 65 63 |de... |`ed' rec|
|000039c0| 6f 67 6e 69 7a 65 73 20 | 74 68 65 20 66 6f 6c 6c |ognizes |the foll|
|000039d0| 6f 77 69 6e 67 20 63 6f | 6d 6d 61 6e 64 73 2e 20 |owing co|mmands. |
|000039e0| 20 54 68 65 20 63 6f 6d | 6d 61 6e 64 73 20 61 72 | The com|mands ar|
|000039f0| 65 20 73 68 6f 77 6e 0a | 74 6f 67 65 74 68 65 72 |e shown.|together|
|00003a00| 20 77 69 74 68 20 74 68 | 65 20 64 65 66 61 75 6c | with th|e defaul|
|00003a10| 74 20 61 64 64 72 65 73 | 73 20 6f 72 20 61 64 64 |t addres|s or add|
|00003a20| 72 65 73 73 20 72 61 6e | 67 65 20 73 75 70 70 6c |ress ran|ge suppl|
|00003a30| 69 65 64 20 69 66 20 6e | 6f 6e 65 20 69 73 0a 73 |ied if n|one is.s|
|00003a40| 70 65 63 69 66 69 65 64 | 20 28 69 6e 20 70 61 72 |pecified| (in par|
|00003a50| 65 6e 74 68 65 73 69 73 | 29 2e 0a 0a 60 28 2e 29 |enthesis|)...`(.)|
|00003a60| 61 27 0a 20 20 20 20 20 | 41 70 70 65 6e 64 73 20 |a'. |Appends |
|00003a70| 74 65 78 74 20 74 6f 20 | 74 68 65 20 62 75 66 66 |text to |the buff|
|00003a80| 65 72 20 61 66 74 65 72 | 20 74 68 65 20 61 64 64 |er after| the add|
|00003a90| 72 65 73 73 65 64 20 6c | 69 6e 65 2e 20 20 54 65 |ressed l|ine. Te|
|00003aa0| 78 74 20 69 73 0a 20 20 | 20 20 20 65 6e 74 65 72 |xt is. | enter|
|00003ab0| 65 64 20 69 6e 20 69 6e | 70 75 74 20 6d 6f 64 65 |ed in in|put mode|
|00003ac0| 2e 20 20 54 68 65 20 63 | 75 72 72 65 6e 74 20 61 |. The c|urrent a|
|00003ad0| 64 64 72 65 73 73 20 69 | 73 20 73 65 74 20 74 6f |ddress i|s set to|
|00003ae0| 20 6c 61 73 74 20 6c 69 | 6e 65 0a 20 20 20 20 20 | last li|ne. |
|00003af0| 65 6e 74 65 72 65 64 2e | 0a 0a 60 28 2e 2c 2e 29 |entered.|..`(.,.)|
|00003b00| 63 27 0a 20 20 20 20 20 | 43 68 61 6e 67 65 73 20 |c'. |Changes |
|00003b10| 6c 69 6e 65 73 20 69 6e | 20 74 68 65 20 62 75 66 |lines in| the buf|
|00003b20| 66 65 72 2e 20 20 54 68 | 65 20 61 64 64 72 65 73 |fer. Th|e addres|
|00003b30| 73 65 64 20 6c 69 6e 65 | 73 20 61 72 65 20 64 65 |sed line|s are de|
|00003b40| 6c 65 74 65 64 20 66 72 | 6f 6d 0a 20 20 20 20 20 |leted fr|om. |
|00003b50| 74 68 65 20 62 75 66 66 | 65 72 2c 20 61 6e 64 20 |the buff|er, and |
|00003b60| 74 65 78 74 20 69 73 20 | 61 70 70 65 6e 64 65 64 |text is |appended|
|00003b70| 20 69 6e 20 74 68 65 69 | 72 20 70 6c 61 63 65 2e | in thei|r place.|
|00003b80| 20 20 54 65 78 74 20 69 | 73 20 65 6e 74 65 72 65 | Text i|s entere|
|00003b90| 64 0a 20 20 20 20 20 69 | 6e 20 69 6e 70 75 74 20 |d. i|n input |
|00003ba0| 6d 6f 64 65 2e 20 20 54 | 68 65 20 63 75 72 72 65 |mode. T|he curre|
|00003bb0| 6e 74 20 61 64 64 72 65 | 73 73 20 69 73 20 73 65 |nt addre|ss is se|
|00003bc0| 74 20 74 6f 20 6c 61 73 | 74 20 6c 69 6e 65 20 65 |t to las|t line e|
|00003bd0| 6e 74 65 72 65 64 2e 0a | 0a 60 28 2e 2c 2e 29 64 |ntered..|.`(.,.)d|
|00003be0| 27 0a 20 20 20 20 20 44 | 65 6c 65 74 65 73 20 74 |'. D|eletes t|
|00003bf0| 68 65 20 61 64 64 72 65 | 73 73 65 64 20 6c 69 6e |he addre|ssed lin|
|00003c00| 65 73 20 66 72 6f 6d 20 | 74 68 65 20 62 75 66 66 |es from |the buff|
|00003c10| 65 72 2e 20 20 49 66 20 | 74 68 65 72 65 20 69 73 |er. If |there is|
|00003c20| 20 61 20 6c 69 6e 65 0a | 20 20 20 20 20 61 66 74 | a line.| aft|
|00003c30| 65 72 20 74 68 65 20 64 | 65 6c 65 74 65 64 20 72 |er the d|eleted r|
|00003c40| 61 6e 67 65 2c 20 74 68 | 65 6e 20 74 68 65 20 63 |ange, th|en the c|
|00003c50| 75 72 72 65 6e 74 20 61 | 64 64 72 65 73 73 20 69 |urrent a|ddress i|
|00003c60| 73 20 73 65 74 20 74 6f | 20 74 68 69 73 0a 20 20 |s set to| this. |
|00003c70| 20 20 20 6c 69 6e 65 2e | 20 20 4f 74 68 65 72 77 | line.| Otherw|
|00003c80| 69 73 65 20 74 68 65 20 | 63 75 72 72 65 6e 74 20 |ise the |current |
|00003c90| 61 64 64 72 65 73 73 20 | 69 73 20 73 65 74 20 74 |address |is set t|
|00003ca0| 6f 20 74 68 65 20 6c 69 | 6e 65 20 62 65 66 6f 72 |o the li|ne befor|
|00003cb0| 65 20 74 68 65 0a 20 20 | 20 20 20 64 65 6c 65 74 |e the. | delet|
|00003cc0| 65 64 20 72 61 6e 67 65 | 2e 0a 0a 60 65 20 46 49 |ed range|...`e FI|
|00003cd0| 4c 45 27 0a 20 20 20 20 | 20 45 64 69 74 73 20 46 |LE'. | Edits F|
|00003ce0| 49 4c 45 2c 20 61 6e 64 | 20 73 65 74 73 20 74 68 |ILE, and| sets th|
|00003cf0| 65 20 64 65 66 61 75 6c | 74 20 66 69 6c 65 6e 61 |e defaul|t filena|
|00003d00| 6d 65 2e 20 20 49 66 20 | 46 49 4c 45 20 69 73 20 |me. If |FILE is |
|00003d10| 6e 6f 74 0a 20 20 20 20 | 20 73 70 65 63 69 66 69 |not. | specifi|
|00003d20| 65 64 2c 20 74 68 65 6e | 20 74 68 65 20 64 65 66 |ed, then| the def|
|00003d30| 61 75 6c 74 20 66 69 6c | 65 6e 61 6d 65 20 69 73 |ault fil|ename is|
|00003d40| 20 75 73 65 64 2e 20 20 | 41 6e 79 20 6c 69 6e 65 | used. |Any line|
|00003d50| 73 20 69 6e 20 74 68 65 | 0a 20 20 20 20 20 62 75 |s in the|. bu|
|00003d60| 66 66 65 72 20 61 72 65 | 20 64 65 6c 65 74 65 64 |ffer are| deleted|
|00003d70| 20 62 65 66 6f 72 65 20 | 74 68 65 20 6e 65 77 20 | before |the new |
|00003d80| 66 69 6c 65 20 69 73 20 | 72 65 61 64 2e 20 20 54 |file is |read. T|
|00003d90| 68 65 20 63 75 72 72 65 | 6e 74 0a 20 20 20 20 20 |he curre|nt. |
|00003da0| 61 64 64 72 65 73 73 20 | 69 73 20 73 65 74 20 74 |address |is set t|
|00003db0| 6f 20 74 68 65 20 6c 61 | 73 74 20 6c 69 6e 65 20 |o the la|st line |
|00003dc0| 72 65 61 64 2e 0a 0a 60 | 65 20 21 43 4f 4d 4d 41 |read...`|e !COMMA|
|00003dd0| 4e 44 27 0a 20 20 20 20 | 20 45 64 69 74 73 20 74 |ND'. | Edits t|
|00003de0| 68 65 20 73 74 61 6e 64 | 61 72 64 20 6f 75 74 70 |he stand|ard outp|
|00003df0| 75 74 20 6f 66 20 60 21 | 43 4f 4d 4d 41 4e 44 27 |ut of `!|COMMAND'|
|00003e00| 2c 20 28 73 65 65 20 60 | 21 27 20 63 6f 6d 6d 61 |, (see `|!' comma|
|00003e10| 6e 64 20 62 65 6c 6f 77 | 29 2e 0a 20 20 20 20 20 |nd below|).. |
|00003e20| 54 68 65 20 64 65 66 61 | 75 6c 74 20 66 69 6c 65 |The defa|ult file|
|00003e30| 6e 61 6d 65 20 69 73 20 | 75 6e 63 68 61 6e 67 65 |name is |unchange|
|00003e40| 64 2e 20 20 41 6e 79 20 | 6c 69 6e 65 73 20 69 6e |d. Any |lines in|
|00003e50| 20 74 68 65 20 62 75 66 | 66 65 72 20 61 72 65 0a | the buf|fer are.|
|00003e60| 20 20 20 20 20 64 65 6c | 65 74 65 64 20 62 65 66 | del|eted bef|
|00003e70| 6f 72 65 20 74 68 65 20 | 6f 75 74 70 75 74 20 6f |ore the |output o|
|00003e80| 66 20 43 4f 4d 4d 41 4e | 44 20 69 73 20 72 65 61 |f COMMAN|D is rea|
|00003e90| 64 2e 20 20 54 68 65 20 | 63 75 72 72 65 6e 74 20 |d. The |current |
|00003ea0| 61 64 64 72 65 73 73 0a | 20 20 20 20 20 69 73 20 |address.| is |
|00003eb0| 73 65 74 20 74 6f 20 74 | 68 65 20 6c 61 73 74 20 |set to t|he last |
|00003ec0| 6c 69 6e 65 20 72 65 61 | 64 2e 0a 0a 60 45 20 46 |line rea|d...`E F|
|00003ed0| 49 4c 45 27 0a 20 20 20 | 20 20 45 64 69 74 73 20 |ILE'. | Edits |
|00003ee0| 46 49 4c 45 20 75 6e 63 | 6f 6e 64 69 74 69 6f 6e |FILE unc|ondition|
|00003ef0| 61 6c 6c 79 2e 20 20 54 | 68 69 73 20 69 73 20 73 |ally. T|his is s|
|00003f00| 69 6d 69 6c 61 72 20 74 | 6f 20 74 68 65 20 60 65 |imilar t|o the `e|
|00003f10| 27 20 63 6f 6d 6d 61 6e | 64 2c 0a 20 20 20 20 20 |' comman|d,. |
|00003f20| 65 78 63 65 70 74 20 74 | 68 61 74 20 75 6e 77 72 |except t|hat unwr|
|00003f30| 69 74 74 65 6e 20 63 68 | 61 6e 67 65 73 20 61 72 |itten ch|anges ar|
|00003f40| 65 20 64 69 73 63 61 72 | 64 65 64 20 77 69 74 68 |e discar|ded with|
|00003f50| 6f 75 74 20 77 61 72 6e | 69 6e 67 2e 20 20 54 68 |out warn|ing. Th|
|00003f60| 65 0a 20 20 20 20 20 63 | 75 72 72 65 6e 74 20 61 |e. c|urrent a|
|00003f70| 64 64 72 65 73 73 20 69 | 73 20 73 65 74 20 74 6f |ddress i|s set to|
|00003f80| 20 74 68 65 20 6c 61 73 | 74 20 6c 69 6e 65 20 72 | the las|t line r|
|00003f90| 65 61 64 2e 0a 0a 60 66 | 20 46 49 4c 45 27 0a 20 |ead...`f| FILE'. |
|00003fa0| 20 20 20 20 53 65 74 73 | 20 74 68 65 20 64 65 66 | Sets| the def|
|00003fb0| 61 75 6c 74 20 66 69 6c | 65 6e 61 6d 65 20 74 6f |ault fil|ename to|
|00003fc0| 20 46 49 4c 45 2e 20 20 | 49 66 20 46 49 4c 45 20 | FILE. |If FILE |
|00003fd0| 69 73 20 6e 6f 74 20 73 | 70 65 63 69 66 69 65 64 |is not s|pecified|
|00003fe0| 2c 20 74 68 65 6e 0a 20 | 20 20 20 20 74 68 65 20 |, then. | the |
|00003ff0| 64 65 66 61 75 6c 74 20 | 75 6e 65 73 63 61 70 65 |default |unescape|
|00004000| 64 20 66 69 6c 65 6e 61 | 6d 65 20 69 73 20 70 72 |d filena|me is pr|
|00004010| 69 6e 74 65 64 2e 0a 0a | 60 28 31 2c 24 29 67 20 |inted...|`(1,$)g |
|00004020| 2f 52 45 2f 43 4f 4d 4d | 41 4e 44 2d 4c 49 53 54 |/RE/COMM|AND-LIST|
|00004030| 27 0a 20 20 20 20 20 41 | 70 70 6c 69 65 73 20 43 |'. A|pplies C|
|00004040| 4f 4d 4d 41 4e 44 2d 4c | 49 53 54 20 74 6f 20 65 |OMMAND-L|IST to e|
|00004050| 61 63 68 20 6f 66 20 74 | 68 65 20 61 64 64 72 65 |ach of t|he addre|
|00004060| 73 73 65 64 20 6c 69 6e | 65 73 20 6d 61 74 63 68 |ssed lin|es match|
|00004070| 69 6e 67 20 61 0a 20 20 | 20 20 20 72 65 67 75 6c |ing a. | regul|
|00004080| 61 72 20 65 78 70 72 65 | 73 73 69 6f 6e 20 52 45 |ar expre|ssion RE|
|00004090| 2e 20 20 54 68 65 20 63 | 75 72 72 65 6e 74 20 61 |. The c|urrent a|
|000040a0| 64 64 72 65 73 73 20 69 | 73 20 73 65 74 20 74 6f |ddress i|s set to|
|000040b0| 20 74 68 65 20 6c 69 6e | 65 0a 20 20 20 20 20 63 | the lin|e. c|
|000040c0| 75 72 72 65 6e 74 6c 79 | 20 6d 61 74 63 68 65 64 |urrently| matched|
|000040d0| 20 62 65 66 6f 72 65 20 | 43 4f 4d 4d 41 4e 44 2d | before |COMMAND-|
|000040e0| 4c 49 53 54 20 69 73 20 | 65 78 65 63 75 74 65 64 |LIST is |executed|
|000040f0| 2e 20 20 41 74 20 74 68 | 65 20 65 6e 64 20 6f 66 |. At th|e end of|
|00004100| 0a 20 20 20 20 20 74 68 | 65 20 60 67 27 20 63 6f |. th|e `g' co|
|00004110| 6d 6d 61 6e 64 2c 20 74 | 68 65 20 63 75 72 72 65 |mmand, t|he curre|
|00004120| 6e 74 20 61 64 64 72 65 | 73 73 20 69 73 20 73 65 |nt addre|ss is se|
|00004130| 74 20 74 6f 20 74 68 65 | 20 6c 61 73 74 20 6c 69 |t to the| last li|
|00004140| 6e 65 0a 20 20 20 20 20 | 61 66 66 65 63 74 65 64 |ne. |affected|
|00004150| 20 62 79 20 43 4f 4d 4d | 41 4e 44 2d 4c 49 53 54 | by COMM|AND-LIST|
|00004160| 2e 0a 0a 20 20 20 20 20 | 45 61 63 68 20 63 6f 6d |... |Each com|
|00004170| 6d 61 6e 64 20 69 6e 20 | 43 4f 4d 4d 41 4e 44 2d |mand in |COMMAND-|
|00004180| 4c 49 53 54 20 6d 75 73 | 74 20 62 65 20 6f 6e 20 |LIST mus|t be on |
|00004190| 61 20 73 65 70 61 72 61 | 74 65 20 6c 69 6e 65 2c |a separa|te line,|
|000041a0| 20 61 6e 64 20 65 76 65 | 72 79 0a 20 20 20 20 20 | and eve|ry. |
|000041b0| 6c 69 6e 65 20 65 78 63 | 65 70 74 20 66 6f 72 20 |line exc|ept for |
|000041c0| 74 68 65 20 6c 61 73 74 | 20 6d 75 73 74 20 62 65 |the last| must be|
|000041d0| 20 74 65 72 6d 69 6e 61 | 74 65 64 20 62 79 20 61 | termina|ted by a|
|000041e0| 20 62 61 63 6b 73 6c 61 | 73 68 20 28 60 5c 27 29 | backsla|sh (`\')|
|000041f0| 2e 0a 20 20 20 20 20 41 | 6e 79 20 63 6f 6d 6d 61 |.. A|ny comma|
|00004200| 6e 64 73 20 61 72 65 20 | 61 6c 6c 6f 77 65 64 2c |nds are |allowed,|
|00004210| 20 65 78 63 65 70 74 20 | 66 6f 72 20 60 67 27 2c | except |for `g',|
|00004220| 20 60 47 27 2c 20 60 76 | 27 2c 20 61 6e 64 20 60 | `G', `v|', and `|
|00004230| 56 27 2e 20 20 41 0a 20 | 20 20 20 20 6e 65 77 6c |V'. A. | newl|
|00004240| 69 6e 65 20 61 6c 6f 6e | 65 20 69 6e 20 43 4f 4d |ine alon|e in COM|
|00004250| 4d 41 4e 44 2d 4c 49 53 | 54 20 69 73 20 65 71 75 |MAND-LIS|T is equ|
|00004260| 69 76 61 6c 65 6e 74 20 | 74 6f 20 61 20 60 70 27 |ivalent |to a `p'|
|00004270| 20 63 6f 6d 6d 61 6e 64 | 2e 0a 0a 60 28 31 2c 24 | command|...`(1,$|
|00004280| 29 47 20 2f 52 45 2f 27 | 0a 20 20 20 20 20 49 6e |)G /RE/'|. In|
|00004290| 74 65 72 61 63 74 69 76 | 65 6c 79 20 65 64 69 74 |teractiv|ely edit|
|000042a0| 73 20 74 68 65 20 61 64 | 64 72 65 73 73 65 64 20 |s the ad|dressed |
|000042b0| 6c 69 6e 65 73 20 6d 61 | 74 63 68 69 6e 67 20 61 |lines ma|tching a|
|000042c0| 20 72 65 67 75 6c 61 72 | 0a 20 20 20 20 20 65 78 | regular|. ex|
|000042d0| 70 72 65 73 73 69 6f 6e | 20 52 45 2e 20 20 46 6f |pression| RE. Fo|
|000042e0| 72 20 65 61 63 68 20 6d | 61 74 63 68 69 6e 67 20 |r each m|atching |
|000042f0| 6c 69 6e 65 2c 20 74 68 | 65 20 6c 69 6e 65 20 69 |line, th|e line i|
|00004300| 73 20 70 72 69 6e 74 65 | 64 2c 20 74 68 65 0a 20 |s printe|d, the. |
|00004310| 20 20 20 20 63 75 72 72 | 65 6e 74 20 61 64 64 72 | curr|ent addr|
|00004320| 65 73 73 20 69 73 20 73 | 65 74 2c 20 61 6e 64 20 |ess is s|et, and |
|00004330| 74 68 65 20 75 73 65 72 | 20 69 73 20 70 72 6f 6d |the user| is prom|
|00004340| 70 74 65 64 20 74 6f 20 | 65 6e 74 65 72 20 61 0a |pted to |enter a.|
|00004350| 20 20 20 20 20 43 4f 4d | 4d 41 4e 44 2d 4c 49 53 | COM|MAND-LIS|
|00004360| 54 2e 20 20 41 74 20 74 | 68 65 20 65 6e 64 20 6f |T. At t|he end o|
|00004370| 66 20 74 68 65 20 60 47 | 27 20 63 6f 6d 6d 61 6e |f the `G|' comman|
|00004380| 64 2c 20 74 68 65 20 63 | 75 72 72 65 6e 74 20 61 |d, the c|urrent a|
|00004390| 64 64 72 65 73 73 0a 20 | 20 20 20 20 69 73 20 73 |ddress. | is s|
|000043a0| 65 74 20 74 6f 20 74 68 | 65 20 6c 61 73 74 20 6c |et to th|e last l|
|000043b0| 69 6e 65 20 61 66 66 65 | 63 74 65 64 20 62 79 20 |ine affe|cted by |
|000043c0| 28 74 68 65 20 6c 61 73 | 74 29 20 43 4f 4d 4d 41 |(the las|t) COMMA|
|000043d0| 4e 44 2d 4c 49 53 54 2e | 0a 0a 20 20 20 20 20 54 |ND-LIST.|.. T|
|000043e0| 68 65 20 66 6f 72 6d 61 | 74 20 6f 66 20 43 4f 4d |he forma|t of COM|
|000043f0| 4d 41 4e 44 2d 4c 49 53 | 54 20 69 73 20 74 68 65 |MAND-LIS|T is the|
|00004400| 20 73 61 6d 65 20 61 73 | 20 74 68 61 74 20 6f 66 | same as| that of|
|00004410| 20 74 68 65 20 60 67 27 | 20 63 6f 6d 6d 61 6e 64 | the `g'| command|
|00004420| 2e 0a 20 20 20 20 20 41 | 20 6e 65 77 6c 69 6e 65 |.. A| newline|
|00004430| 20 61 6c 6f 6e 65 20 61 | 63 74 73 20 61 73 20 61 | alone a|cts as a|
|00004440| 20 6e 75 6c 6c 20 63 6f | 6d 6d 61 6e 64 20 6c 69 | null co|mmand li|
|00004450| 73 74 2e 20 20 41 20 73 | 69 6e 67 6c 65 20 60 26 |st. A s|ingle `&|
|00004460| 27 0a 20 20 20 20 20 72 | 65 70 65 61 74 73 20 74 |'. r|epeats t|
|00004470| 68 65 20 6c 61 73 74 20 | 6e 6f 6e 2d 6e 75 6c 6c |he last |non-null|
|00004480| 20 63 6f 6d 6d 61 6e 64 | 20 6c 69 73 74 2e 0a 0a | command| list...|
|00004490| 60 48 27 0a 20 20 20 20 | 20 54 6f 67 67 6c 65 73 |`H'. | Toggles|
|000044a0| 20 74 68 65 20 70 72 69 | 6e 74 69 6e 67 20 6f 66 | the pri|nting of|
|000044b0| 20 65 72 72 6f 72 20 65 | 78 70 6c 61 6e 61 74 69 | error e|xplanati|
|000044c0| 6f 6e 73 2e 20 20 42 79 | 20 64 65 66 61 75 6c 74 |ons. By| default|
|000044d0| 2c 0a 20 20 20 20 20 65 | 78 70 6c 61 6e 61 74 69 |,. e|xplanati|
|000044e0| 6f 6e 73 20 61 72 65 20 | 6e 6f 74 20 70 72 69 6e |ons are |not prin|
|000044f0| 74 65 64 2e 20 20 49 74 | 20 69 73 20 72 65 63 6f |ted. It| is reco|
|00004500| 6d 6d 65 6e 64 65 64 20 | 74 68 61 74 20 65 64 20 |mmended |that ed |
|00004510| 73 63 72 69 70 74 73 0a | 20 20 20 20 20 62 65 67 |scripts.| beg|
|00004520| 69 6e 20 77 69 74 68 20 | 74 68 69 73 20 63 6f 6d |in with |this com|
|00004530| 6d 61 6e 64 20 74 6f 20 | 61 69 64 20 69 6e 20 64 |mand to |aid in d|
|00004540| 65 62 75 67 67 69 6e 67 | 2e 0a 0a 60 68 27 0a 20 |ebugging|...`h'. |
|00004550| 20 20 20 20 50 72 69 6e | 74 73 20 61 6e 20 65 78 | Prin|ts an ex|
|00004560| 70 6c 61 6e 61 74 69 6f | 6e 20 6f 66 20 74 68 65 |planatio|n of the|
|00004570| 20 6c 61 73 74 20 65 72 | 72 6f 72 2e 0a 0a 60 28 | last er|ror...`(|
|00004580| 2e 29 69 27 0a 20 20 20 | 20 20 49 6e 73 65 72 74 |.)i'. | Insert|
|00004590| 73 20 74 65 78 74 20 69 | 6e 20 74 68 65 20 62 75 |s text i|n the bu|
|000045a0| 66 66 65 72 20 62 65 66 | 6f 72 65 20 74 68 65 20 |ffer bef|ore the |
|000045b0| 63 75 72 72 65 6e 74 20 | 6c 69 6e 65 2e 20 20 54 |current |line. T|
|000045c0| 65 78 74 20 69 73 0a 20 | 20 20 20 20 65 6e 74 65 |ext is. | ente|
|000045d0| 72 65 64 20 69 6e 20 69 | 6e 70 75 74 20 6d 6f 64 |red in i|nput mod|
|000045e0| 65 2e 20 20 54 68 65 20 | 63 75 72 72 65 6e 74 20 |e. The |current |
|000045f0| 61 64 64 72 65 73 73 20 | 69 73 20 73 65 74 20 74 |address |is set t|
|00004600| 6f 20 74 68 65 20 6c 61 | 73 74 0a 20 20 20 20 20 |o the la|st. |
|00004610| 6c 69 6e 65 20 65 6e 74 | 65 72 65 64 2e 0a 0a 60 |line ent|ered...`|
|00004620| 28 2e 2c 2e 2b 31 29 6a | 27 0a 20 20 20 20 20 4a |(.,.+1)j|'. J|
|00004630| 6f 69 6e 73 20 74 68 65 | 20 61 64 64 72 65 73 73 |oins the| address|
|00004640| 65 64 20 6c 69 6e 65 73 | 2e 20 20 54 68 65 20 61 |ed lines|. The a|
|00004650| 64 64 72 65 73 73 65 64 | 20 6c 69 6e 65 73 20 61 |ddressed| lines a|
|00004660| 72 65 20 64 65 6c 65 74 | 65 64 20 66 72 6f 6d 0a |re delet|ed from.|
|00004670| 20 20 20 20 20 74 68 65 | 20 62 75 66 66 65 72 20 | the| buffer |
|00004680| 61 6e 64 20 72 65 70 6c | 61 63 65 64 20 62 79 20 |and repl|aced by |
|00004690| 61 20 73 69 6e 67 6c 65 | 20 6c 69 6e 65 20 63 6f |a single| line co|
|000046a0| 6e 74 61 69 6e 69 6e 67 | 20 74 68 65 69 72 20 6a |ntaining| their j|
|000046b0| 6f 69 6e 65 64 0a 20 20 | 20 20 20 74 65 78 74 2e |oined. | text.|
|000046c0| 20 20 54 68 65 20 63 75 | 72 72 65 6e 74 20 61 64 | The cu|rrent ad|
|000046d0| 64 72 65 73 73 20 69 73 | 20 73 65 74 20 74 6f 20 |dress is| set to |
|000046e0| 74 68 65 20 72 65 73 75 | 6c 74 61 6e 74 20 6c 69 |the resu|ltant li|
|000046f0| 6e 65 2e 0a 0a 60 28 2e | 29 6b 20 4c 43 27 0a 20 |ne...`(.|)k LC'. |
|00004700| 20 20 20 20 4d 61 72 6b | 73 20 61 20 6c 69 6e 65 | Mark|s a line|
|00004710| 20 77 69 74 68 20 61 20 | 6c 6f 77 65 72 20 63 61 | with a |lower ca|
|00004720| 73 65 20 6c 65 74 74 65 | 72 20 4c 43 2e 20 20 54 |se lette|r LC. T|
|00004730| 68 65 20 6c 69 6e 65 20 | 63 61 6e 20 74 68 65 6e |he line |can then|
|00004740| 20 62 65 0a 20 20 20 20 | 20 61 64 64 72 65 73 73 | be. | address|
|00004750| 65 64 20 61 73 20 60 27 | 4c 43 27 20 28 69 2e 65 |ed as `'|LC' (i.e|
|00004760| 2e 2c 20 61 20 73 69 6e | 67 6c 65 20 71 75 6f 74 |., a sin|gle quot|
|00004770| 65 20 66 6f 6c 6c 6f 77 | 65 64 20 62 79 20 4c 43 |e follow|ed by LC|
|00004780| 29 20 69 6e 0a 20 20 20 | 20 20 73 75 62 73 65 71 |) in. | subseq|
|00004790| 75 65 6e 74 20 63 6f 6d | 6d 61 6e 64 73 2e 20 20 |uent com|mands. |
|000047a0| 54 68 65 20 6d 61 72 6b | 20 69 73 20 6e 6f 74 20 |The mark| is not |
|000047b0| 63 6c 65 61 72 65 64 20 | 75 6e 74 69 6c 20 74 68 |cleared |until th|
|000047c0| 65 20 6c 69 6e 65 20 69 | 73 0a 20 20 20 20 20 64 |e line i|s. d|
|000047d0| 65 6c 65 74 65 64 20 6f | 72 20 6f 74 68 65 72 77 |eleted o|r otherw|
|000047e0| 69 73 65 20 6d 6f 64 69 | 66 69 65 64 2e 0a 0a 60 |ise modi|fied...`|
|000047f0| 28 2e 2c 2e 29 6c 27 0a | 20 20 20 20 20 50 72 69 |(.,.)l'.| Pri|
|00004800| 6e 74 73 20 74 68 65 20 | 61 64 64 72 65 73 73 65 |nts the |addresse|
|00004810| 64 20 6c 69 6e 65 73 20 | 75 6e 61 6d 62 69 67 75 |d lines |unambigu|
|00004820| 6f 75 73 6c 79 2e 20 20 | 49 66 20 61 20 73 69 6e |ously. |If a sin|
|00004830| 67 6c 65 20 6c 69 6e 65 | 20 66 69 6c 6c 73 0a 20 |gle line| fills. |
|00004840| 20 20 20 20 66 6f 72 20 | 74 68 61 6e 20 6f 6e 65 | for |than one|
|00004850| 20 73 63 72 65 65 6e 20 | 28 61 73 20 6d 69 67 68 | screen |(as migh|
|00004860| 74 20 62 65 20 74 68 65 | 20 63 61 73 65 20 77 68 |t be the| case wh|
|00004870| 65 6e 20 76 69 65 77 69 | 6e 67 20 61 20 62 69 6e |en viewi|ng a bin|
|00004880| 61 72 79 0a 20 20 20 20 | 20 66 69 6c 65 2c 20 66 |ary. | file, f|
|00004890| 6f 72 20 69 6e 73 74 61 | 6e 63 65 29 2c 20 61 20 |or insta|nce), a |
|000048a0| 60 2d 2d 4d 6f 72 65 2d | 2d 27 20 70 72 6f 6d 70 |`--More-|-' promp|
|000048b0| 74 20 69 73 20 70 72 69 | 6e 74 65 64 20 6f 6e 20 |t is pri|nted on |
|000048c0| 74 68 65 20 6c 61 73 74 | 0a 20 20 20 20 20 6c 69 |the last|. li|
|000048d0| 6e 65 2e 20 20 60 65 64 | 27 20 77 61 69 74 73 20 |ne. `ed|' waits |
|000048e0| 75 6e 74 69 6c 20 74 68 | 65 20 52 45 54 55 52 4e |until th|e RETURN|
|000048f0| 20 6b 65 79 20 69 73 20 | 70 72 65 73 73 65 64 20 | key is |pressed |
|00004900| 62 65 66 6f 72 65 20 64 | 69 73 70 6c 61 79 69 6e |before d|isplayin|
|00004910| 67 0a 20 20 20 20 20 74 | 68 65 20 6e 65 78 74 20 |g. t|he next |
|00004920| 73 63 72 65 65 6e 2e 20 | 20 54 68 65 20 63 75 72 |screen. | The cur|
|00004930| 72 65 6e 74 20 61 64 64 | 72 65 73 73 20 69 73 20 |rent add|ress is |
|00004940| 73 65 74 20 74 6f 20 74 | 68 65 20 6c 61 73 74 20 |set to t|he last |
|00004950| 6c 69 6e 65 0a 20 20 20 | 20 20 70 72 69 6e 74 65 |line. | printe|
|00004960| 64 2e 0a 0a 60 28 2e 2c | 2e 29 6d 28 2e 29 27 0a |d...`(.,|.)m(.)'.|
|00004970| 20 20 20 20 20 4d 6f 76 | 65 73 20 6c 69 6e 65 73 | Mov|es lines|
|00004980| 20 69 6e 20 74 68 65 20 | 62 75 66 66 65 72 2e 20 | in the |buffer. |
|00004990| 20 54 68 65 20 61 64 64 | 72 65 73 73 65 64 20 6c | The add|ressed l|
|000049a0| 69 6e 65 73 20 61 72 65 | 20 6d 6f 76 65 64 20 74 |ines are| moved t|
|000049b0| 6f 20 61 66 74 65 72 0a | 20 20 20 20 20 74 68 65 |o after.| the|
|000049c0| 20 72 69 67 68 74 2d 68 | 61 6e 64 20 64 65 73 74 | right-h|and dest|
|000049d0| 69 6e 61 74 69 6f 6e 20 | 61 64 64 72 65 73 73 2c |ination |address,|
|000049e0| 20 77 68 69 63 68 20 6d | 61 79 20 62 65 20 74 68 | which m|ay be th|
|000049f0| 65 20 61 64 64 72 65 73 | 73 20 60 30 27 0a 20 20 |e addres|s `0'. |
|00004a00| 20 20 20 28 7a 65 72 6f | 29 2e 20 20 54 68 65 20 | (zero|). The |
|00004a10| 63 75 72 72 65 6e 74 20 | 61 64 64 72 65 73 73 20 |current |address |
|00004a20| 69 73 20 73 65 74 20 74 | 6f 20 74 68 65 20 6c 61 |is set t|o the la|
|00004a30| 73 74 20 6c 69 6e 65 20 | 6d 6f 76 65 64 2e 0a 0a |st line |moved...|
|00004a40| 60 28 2e 2c 2e 29 6e 27 | 0a 20 20 20 20 20 50 72 |`(.,.)n'|. Pr|
|00004a50| 69 6e 74 73 20 74 68 65 | 20 61 64 64 72 65 73 73 |ints the| address|
|00004a60| 65 64 20 6c 69 6e 65 73 | 20 61 6c 6f 6e 67 20 77 |ed lines| along w|
|00004a70| 69 74 68 20 74 68 65 69 | 72 20 6c 69 6e 65 20 6e |ith thei|r line n|
|00004a80| 75 6d 62 65 72 73 2e 20 | 20 54 68 65 0a 20 20 20 |umbers. | The. |
|00004a90| 20 20 63 75 72 72 65 6e | 74 20 61 64 64 72 65 73 | curren|t addres|
|00004aa0| 73 20 69 73 20 73 65 74 | 20 74 6f 20 74 68 65 20 |s is set| to the |
|00004ab0| 6c 61 73 74 20 6c 69 6e | 65 20 70 72 69 6e 74 65 |last lin|e printe|
|00004ac0| 64 2e 0a 0a 60 28 2e 2c | 2e 29 70 27 0a 20 20 20 |d...`(.,|.)p'. |
|00004ad0| 20 20 50 72 69 6e 74 73 | 20 74 68 65 20 61 64 64 | Prints| the add|
|00004ae0| 72 65 73 73 65 64 20 6c | 69 6e 65 73 2e 20 54 68 |ressed l|ines. Th|
|00004af0| 65 20 63 75 72 72 65 6e | 74 20 61 64 64 72 65 73 |e curren|t addres|
|00004b00| 73 20 69 73 20 73 65 74 | 20 74 6f 20 74 68 65 20 |s is set| to the |
|00004b10| 6c 61 73 74 0a 20 20 20 | 20 20 6c 69 6e 65 20 70 |last. | line p|
|00004b20| 72 69 6e 74 65 64 2e 0a | 0a 60 50 27 0a 20 20 20 |rinted..|.`P'. |
|00004b30| 20 20 54 6f 67 67 6c 65 | 73 20 74 68 65 20 63 6f | Toggle|s the co|
|00004b40| 6d 6d 61 6e 64 20 70 72 | 6f 6d 70 74 20 6f 6e 20 |mmand pr|ompt on |
|00004b50| 61 6e 64 20 6f 66 66 2e | 20 20 55 6e 6c 65 73 73 |and off.| Unless|
|00004b60| 20 61 20 70 72 6f 6d 70 | 74 20 77 61 73 0a 20 20 | a promp|t was. |
|00004b70| 20 20 20 73 70 65 63 69 | 66 69 65 64 20 62 79 20 | speci|fied by |
|00004b80| 77 69 74 68 20 63 6f 6d | 6d 61 6e 64 2d 6c 69 6e |with com|mand-lin|
|00004b90| 65 20 6f 70 74 69 6f 6e | 20 60 2d 70 20 53 54 52 |e option| `-p STR|
|00004ba0| 49 4e 47 27 2c 20 74 68 | 65 20 63 6f 6d 6d 61 6e |ING', th|e comman|
|00004bb0| 64 0a 20 20 20 20 20 70 | 72 6f 6d 70 74 20 69 73 |d. p|rompt is|
|00004bc0| 20 62 79 20 64 65 66 61 | 75 6c 74 20 74 75 72 6e | by defa|ult turn|
|00004bd0| 65 64 20 6f 66 66 2e 0a | 0a 60 71 27 0a 20 20 20 |ed off..|.`q'. |
|00004be0| 20 20 51 75 69 74 73 20 | 60 65 64 27 2e 0a 0a 60 | Quits |`ed'...`|
|00004bf0| 51 27 0a 20 20 20 20 20 | 51 75 69 74 73 20 60 65 |Q'. |Quits `e|
|00004c00| 64 27 20 75 6e 63 6f 6e | 64 69 74 69 6f 6e 61 6c |d' uncon|ditional|
|00004c10| 6c 79 2e 20 20 54 68 69 | 73 20 69 73 20 73 69 6d |ly. Thi|s is sim|
|00004c20| 69 6c 61 72 20 74 6f 20 | 74 68 65 20 60 71 27 20 |ilar to |the `q' |
|00004c30| 63 6f 6d 6d 61 6e 64 2c | 0a 20 20 20 20 20 65 78 |command,|. ex|
|00004c40| 63 65 70 74 20 74 68 61 | 74 20 75 6e 77 72 69 74 |cept tha|t unwrit|
|00004c50| 74 65 6e 20 63 68 61 6e | 67 65 73 20 61 72 65 20 |ten chan|ges are |
|00004c60| 64 69 73 63 61 72 64 65 | 64 20 77 69 74 68 6f 75 |discarde|d withou|
|00004c70| 74 20 77 61 72 6e 69 6e | 67 2e 0a 0a 60 28 24 29 |t warnin|g...`($)|
|00004c80| 72 20 46 49 4c 45 27 0a | 20 20 20 20 20 52 65 61 |r FILE'.| Rea|
|00004c90| 64 73 20 46 49 4c 45 20 | 74 6f 20 61 66 74 65 72 |ds FILE |to after|
|00004ca0| 20 74 68 65 20 61 64 64 | 72 65 73 73 65 64 20 6c | the add|ressed l|
|00004cb0| 69 6e 65 2e 20 20 49 66 | 20 46 49 4c 45 20 69 73 |ine. If| FILE is|
|00004cc0| 20 6e 6f 74 20 73 70 65 | 63 69 66 69 65 64 2c 0a | not spe|cified,.|
|00004cd0| 20 20 20 20 20 74 68 65 | 6e 20 74 68 65 20 64 65 | the|n the de|
|00004ce0| 66 61 75 6c 74 20 66 69 | 6c 65 6e 61 6d 65 20 69 |fault fi|lename i|
|00004cf0| 73 20 75 73 65 64 2e 20 | 20 49 66 20 74 68 65 72 |s used. | If ther|
|00004d00| 65 20 77 61 73 20 6e 6f | 20 64 65 66 61 75 6c 74 |e was no| default|
|00004d10| 0a 20 20 20 20 20 66 69 | 6c 65 6e 61 6d 65 20 70 |. fi|lename p|
|00004d20| 72 69 6f 72 20 74 6f 20 | 74 68 65 20 63 6f 6d 6d |rior to |the comm|
|00004d30| 61 6e 64 2c 20 74 68 65 | 6e 20 74 68 65 20 64 65 |and, the|n the de|
|00004d40| 66 61 75 6c 74 20 66 69 | 6c 65 6e 61 6d 65 20 69 |fault fi|lename i|
|00004d50| 73 20 73 65 74 20 74 6f | 0a 20 20 20 20 20 46 49 |s set to|. FI|
|00004d60| 4c 45 2e 20 20 4f 74 68 | 65 72 77 69 73 65 2c 20 |LE. Oth|erwise, |
|00004d70| 74 68 65 20 64 65 66 61 | 75 6c 74 20 66 69 6c 65 |the defa|ult file|
|00004d80| 6e 61 6d 65 20 69 73 20 | 75 6e 63 68 61 6e 67 65 |name is |unchange|
|00004d90| 64 2e 20 20 54 68 65 20 | 63 75 72 72 65 6e 74 0a |d. The |current.|
|00004da0| 20 20 20 20 20 61 64 64 | 72 65 73 73 20 69 73 20 | add|ress is |
|00004db0| 73 65 74 20 74 6f 20 74 | 68 65 20 6c 61 73 74 20 |set to t|he last |
|00004dc0| 6c 69 6e 65 20 72 65 61 | 64 2e 0a 0a 60 28 24 29 |line rea|d...`($)|
|00004dd0| 72 20 21 43 4f 4d 4d 41 | 4e 44 27 0a 20 20 20 20 |r !COMMA|ND'. |
|00004de0| 20 52 65 61 64 73 20 74 | 6f 20 61 66 74 65 72 20 | Reads t|o after |
|00004df0| 74 68 65 20 61 64 64 72 | 65 73 73 65 64 20 6c 69 |the addr|essed li|
|00004e00| 6e 65 20 74 68 65 20 73 | 74 61 6e 64 61 72 64 20 |ne the s|tandard |
|00004e10| 6f 75 74 70 75 74 20 6f | 66 0a 20 20 20 20 20 60 |output o|f. `|
|00004e20| 21 63 6f 6d 6d 61 6e 64 | 27 2c 20 28 73 65 65 20 |!command|', (see |
|00004e30| 74 68 65 20 60 21 27 20 | 63 6f 6d 6d 61 6e 64 20 |the `!' |command |
|00004e40| 62 65 6c 6f 77 29 2e 20 | 20 54 68 65 20 64 65 66 |below). | The def|
|00004e50| 61 75 6c 74 20 66 69 6c | 65 6e 61 6d 65 20 69 73 |ault fil|ename is|
|00004e60| 0a 20 20 20 20 20 75 6e | 63 68 61 6e 67 65 64 2e |. un|changed.|
|00004e70| 20 20 54 68 65 20 63 75 | 72 72 65 6e 74 20 61 64 | The cu|rrent ad|
|00004e80| 64 72 65 73 73 20 69 73 | 20 73 65 74 20 74 6f 20 |dress is| set to |
|00004e90| 74 68 65 20 6c 61 73 74 | 20 6c 69 6e 65 20 72 65 |the last| line re|
|00004ea0| 61 64 2e 0a 0a 60 28 2e | 2c 2e 29 73 20 2f 52 45 |ad...`(.|,.)s /RE|
|00004eb0| 2f 52 45 50 4c 41 43 45 | 4d 45 4e 54 2f 27 0a 60 |/REPLACE|MENT/'.`|
|00004ec0| 28 2e 2c 2e 29 73 20 2f | 52 45 2f 52 45 50 4c 41 |(.,.)s /|RE/REPLA|
|00004ed0| 43 45 4d 45 4e 54 2f 67 | 27 0a 60 28 2e 2c 2e 29 |CEMENT/g|'.`(.,.)|
|00004ee0| 73 20 2f 52 45 2f 52 45 | 50 4c 41 43 45 4d 45 4e |s /RE/RE|PLACEMEN|
|00004ef0| 54 2f 6e 27 0a 20 20 20 | 20 20 52 65 70 6c 61 63 |T/n'. | Replac|
|00004f00| 65 73 20 74 65 78 74 20 | 69 6e 20 74 68 65 20 61 |es text |in the a|
|00004f10| 64 64 72 65 73 73 65 64 | 20 6c 69 6e 65 73 20 6d |ddressed| lines m|
|00004f20| 61 74 63 68 69 6e 67 20 | 61 20 72 65 67 75 6c 61 |atching |a regula|
|00004f30| 72 20 65 78 70 72 65 73 | 73 69 6f 6e 0a 20 20 20 |r expres|sion. |
|00004f40| 20 20 52 45 20 77 69 74 | 68 20 52 45 50 4c 41 43 | RE wit|h REPLAC|
|00004f50| 45 4d 45 4e 54 2e 20 20 | 42 79 20 64 65 66 61 75 |EMENT. |By defau|
|00004f60| 6c 74 2c 20 6f 6e 6c 79 | 20 74 68 65 20 66 69 72 |lt, only| the fir|
|00004f70| 73 74 20 6d 61 74 63 68 | 20 69 6e 20 65 61 63 68 |st match| in each|
|00004f80| 0a 20 20 20 20 20 6c 69 | 6e 65 20 69 73 20 72 65 |. li|ne is re|
|00004f90| 70 6c 61 63 65 64 2e 20 | 20 49 66 20 74 68 65 20 |placed. | If the |
|00004fa0| 60 67 27 20 28 67 6c 6f | 62 61 6c 29 20 73 75 66 |`g' (glo|bal) suf|
|00004fb0| 66 69 78 20 69 73 20 67 | 69 76 65 6e 2c 20 74 68 |fix is g|iven, th|
|00004fc0| 65 6e 20 65 76 65 72 79 | 0a 20 20 20 20 20 6d 61 |en every|. ma|
|00004fd0| 74 63 68 20 74 6f 20 62 | 65 20 72 65 70 6c 61 63 |tch to b|e replac|
|00004fe0| 65 64 2e 20 20 54 68 65 | 20 60 6e 27 20 73 75 66 |ed. The| `n' suf|
|00004ff0| 66 69 78 2c 20 77 68 65 | 72 65 20 4e 20 69 73 20 |fix, whe|re N is |
|00005000| 61 20 70 6f 73 74 69 76 | 65 0a 20 20 20 20 20 6e |a postiv|e. n|
|00005010| 75 6d 62 65 72 2c 20 63 | 61 75 73 65 73 20 6f 6e |umber, c|auses on|
|00005020| 6c 79 20 74 68 65 20 4e | 74 68 20 6d 61 74 63 68 |ly the N|th match|
|00005030| 20 74 6f 20 62 65 20 72 | 65 70 6c 61 63 65 64 2e | to be r|eplaced.|
|00005040| 20 20 49 74 20 69 73 20 | 61 6e 20 65 72 72 6f 72 | It is |an error|
|00005050| 0a 20 20 20 20 20 69 66 | 20 6e 6f 20 73 75 62 73 |. if| no subs|
|00005060| 74 69 74 75 74 69 6f 6e | 73 20 61 72 65 20 70 65 |titution|s are pe|
|00005070| 72 66 6f 72 6d 65 64 20 | 6f 6e 20 61 6e 79 20 6f |rformed |on any o|
|00005080| 66 20 74 68 65 20 61 64 | 64 72 65 73 73 65 64 20 |f the ad|dressed |
|00005090| 6c 69 6e 65 73 2e 0a 20 | 20 20 20 20 54 68 65 20 |lines.. | The |
|000050a0| 63 75 72 72 65 6e 74 20 | 61 64 64 72 65 73 73 20 |current |address |
|000050b0| 69 73 20 73 65 74 20 74 | 68 65 20 6c 61 73 74 20 |is set t|he last |
|000050c0| 6c 69 6e 65 20 61 66 66 | 65 63 74 65 64 2e 0a 0a |line aff|ected...|
|000050d0| 20 20 20 20 20 52 45 20 | 61 6e 64 20 52 45 50 4c | RE |and REPL|
|000050e0| 41 43 45 4d 45 4e 54 20 | 6d 61 79 20 62 65 20 64 |ACEMENT |may be d|
|000050f0| 65 6c 69 6d 69 74 65 64 | 20 62 79 20 61 6e 79 20 |elimited| by any |
|00005100| 63 68 61 72 61 63 74 65 | 72 20 6f 74 68 65 72 20 |characte|r other |
|00005110| 74 68 61 6e 0a 20 20 20 | 20 20 73 70 61 63 65 20 |than. | space |
|00005120| 61 6e 64 20 6e 65 77 6c | 69 6e 65 20 28 73 65 65 |and newl|ine (see|
|00005130| 20 74 68 65 20 60 73 27 | 20 63 6f 6d 6d 61 6e 64 | the `s'| command|
|00005140| 20 62 65 6c 6f 77 29 2e | 20 20 49 66 20 6f 6e 65 | below).| If one|
|00005150| 20 6f 72 20 74 77 6f 20 | 6f 66 0a 20 20 20 20 20 | or two |of. |
|00005160| 74 68 65 20 6c 61 73 74 | 20 64 65 6c 69 6d 69 74 |the last| delimit|
|00005170| 65 72 73 20 69 73 20 6f | 6d 69 74 74 65 64 2c 20 |ers is o|mitted, |
|00005180| 74 68 65 6e 20 74 68 65 | 20 6c 61 73 74 20 6c 69 |then the| last li|
|00005190| 6e 65 20 61 66 66 65 63 | 74 65 64 20 69 73 0a 20 |ne affec|ted is. |
|000051a0| 20 20 20 20 70 72 69 6e | 74 65 64 20 61 73 20 74 | prin|ted as t|
|000051b0| 68 6f 75 67 68 20 74 68 | 65 20 70 72 69 6e 74 20 |hough th|e print |
|000051c0| 73 75 66 66 69 78 20 60 | 70 27 20 77 65 72 65 20 |suffix `|p' were |
|000051d0| 73 70 65 63 69 66 69 65 | 64 2e 0a 0a 20 20 20 20 |specifie|d... |
|000051e0| 20 41 6e 20 75 6e 65 73 | 63 61 70 65 64 20 60 26 | An unes|caped `&|
|000051f0| 27 20 69 6e 20 52 45 50 | 4c 41 43 45 4d 45 4e 54 |' in REP|LACEMENT|
|00005200| 20 69 73 20 72 65 70 6c | 61 63 65 64 20 62 79 20 | is repl|aced by |
|00005210| 74 68 65 20 63 75 72 72 | 65 6e 74 6c 79 0a 20 20 |the curr|ently. |
|00005220| 20 20 20 6d 61 74 63 68 | 65 64 20 74 65 78 74 2e | match|ed text.|
|00005230| 20 20 54 68 65 20 63 68 | 61 72 61 63 74 65 72 20 | The ch|aracter |
|00005240| 73 65 71 75 65 6e 63 65 | 20 60 5c 4d 27 20 77 68 |sequence| `\M' wh|
|00005250| 65 72 65 20 4d 20 69 73 | 20 61 20 6e 75 6d 62 65 |ere M is| a numbe|
|00005260| 72 20 69 6e 0a 20 20 20 | 20 20 74 68 65 20 72 61 |r in. | the ra|
|00005270| 6e 67 65 20 5b 31 2c 39 | 5d 2c 20 69 73 20 72 65 |nge [1,9|], is re|
|00005280| 70 6c 61 63 65 64 20 62 | 79 20 74 68 65 20 4d 74 |placed b|y the Mt|
|00005290| 68 20 62 61 63 6b 72 65 | 66 65 72 65 6e 63 65 20 |h backre|ference |
|000052a0| 65 78 70 72 65 73 73 69 | 6f 6e 0a 20 20 20 20 20 |expressi|on. |
|000052b0| 6f 66 20 74 68 65 20 6d | 61 74 63 68 65 64 20 74 |of the m|atched t|
|000052c0| 65 78 74 2e 20 20 49 66 | 20 52 45 50 4c 41 43 45 |ext. If| REPLACE|
|000052d0| 4d 45 4e 54 20 63 6f 6e | 73 69 73 74 73 20 6f 66 |MENT con|sists of|
|000052e0| 20 61 20 73 69 6e 67 6c | 65 20 60 25 27 2c 0a 20 | a singl|e `%',. |
|000052f0| 20 20 20 20 74 68 65 6e | 20 52 45 50 4c 41 43 45 | then| REPLACE|
|00005300| 4d 45 4e 54 20 66 72 6f | 6d 20 74 68 65 20 6c 61 |MENT fro|m the la|
|00005310| 73 74 20 73 75 62 73 74 | 69 74 75 74 69 6f 6e 20 |st subst|itution |
|00005320| 69 73 20 75 73 65 64 2e | 20 20 4e 65 77 6c 69 6e |is used.| Newlin|
|00005330| 65 73 20 6d 61 79 0a 20 | 20 20 20 20 62 65 20 65 |es may. | be e|
|00005340| 6d 62 65 64 64 65 64 20 | 69 6e 20 52 45 50 4c 41 |mbedded |in REPLA|
|00005350| 43 45 4d 45 4e 54 20 69 | 66 20 74 68 65 79 20 61 |CEMENT i|f they a|
|00005360| 72 65 20 65 73 63 61 70 | 65 64 20 77 69 74 68 20 |re escap|ed with |
|00005370| 61 20 62 61 63 6b 73 6c | 61 73 68 0a 20 20 20 20 |a backsl|ash. |
|00005380| 20 28 60 5c 27 29 2e 0a | 0a 60 28 2e 2c 2e 29 73 | (`\')..|.`(.,.)s|
|00005390| 27 0a 20 20 20 20 20 52 | 65 70 65 61 74 73 20 74 |'. R|epeats t|
|000053a0| 68 65 20 6c 61 73 74 20 | 73 75 62 73 74 69 74 75 |he last |substitu|
|000053b0| 74 69 6f 6e 2e 20 20 54 | 68 69 73 20 66 6f 72 6d |tion. T|his form|
|000053c0| 20 6f 66 20 74 68 65 20 | 60 73 27 20 63 6f 6d 6d | of the |`s' comm|
|000053d0| 61 6e 64 0a 20 20 20 20 | 20 61 63 63 65 70 74 73 |and. | accepts|
|000053e0| 20 61 20 63 6f 75 6e 74 | 20 73 75 66 66 69 78 20 | a count| suffix |
|000053f0| 4e 2c 20 6f 72 20 61 6e | 79 20 63 6f 6d 62 69 6e |N, or an|y combin|
|00005400| 61 74 69 6f 6e 20 6f 66 | 20 74 68 65 20 63 68 61 |ation of| the cha|
|00005410| 72 61 63 74 65 72 73 0a | 20 20 20 20 20 60 72 27 |racters.| `r'|
|00005420| 2c 20 60 67 27 2c 20 61 | 6e 64 20 60 70 27 2e 20 |, `g', a|nd `p'. |
|00005430| 20 49 66 20 61 20 63 6f | 75 6e 74 20 73 75 66 66 | If a co|unt suff|
|00005440| 69 78 20 4e 20 69 73 20 | 67 69 76 65 6e 2c 20 74 |ix N is |given, t|
|00005450| 68 65 6e 20 6f 6e 6c 79 | 20 74 68 65 0a 20 20 20 |hen only| the. |
|00005460| 20 20 4e 74 68 20 6d 61 | 74 63 68 20 69 73 20 72 | Nth ma|tch is r|
|00005470| 65 70 6c 61 63 65 64 2e | 20 20 54 68 65 20 60 72 |eplaced.| The `r|
|00005480| 27 20 73 75 66 66 69 78 | 20 63 61 75 73 65 73 20 |' suffix| causes |
|00005490| 74 68 65 20 72 65 67 75 | 6c 61 72 0a 20 20 20 20 |the regu|lar. |
|000054a0| 20 65 78 70 72 65 73 73 | 69 6f 6e 20 6f 66 20 74 | express|ion of t|
|000054b0| 68 65 20 6c 61 73 74 20 | 73 65 61 72 63 68 20 74 |he last |search t|
|000054c0| 6f 20 62 65 20 75 73 65 | 64 20 69 6e 73 74 65 61 |o be use|d instea|
|000054d0| 64 20 6f 66 20 74 68 65 | 20 74 68 61 74 20 6f 66 |d of the| that of|
|000054e0| 0a 20 20 20 20 20 74 68 | 65 20 6c 61 73 74 20 73 |. th|e last s|
|000054f0| 75 62 73 74 69 74 75 74 | 69 6f 6e 2e 20 20 54 68 |ubstitut|ion. Th|
|00005500| 65 20 60 67 27 20 73 75 | 66 66 69 78 20 74 6f 67 |e `g' su|ffix tog|
|00005510| 67 6c 65 73 20 74 68 65 | 20 67 6c 6f 62 61 6c 20 |gles the| global |
|00005520| 73 75 66 66 69 78 0a 20 | 20 20 20 20 6f 66 20 74 |suffix. | of t|
|00005530| 68 65 20 6c 61 73 74 20 | 73 75 62 73 74 69 74 75 |he last |substitu|
|00005540| 74 69 6f 6e 2e 20 20 54 | 68 65 20 60 70 27 20 73 |tion. T|he `p' s|
|00005550| 75 66 66 69 78 20 74 6f | 67 67 6c 65 73 20 74 68 |uffix to|ggles th|
|00005560| 65 20 70 72 69 6e 74 20 | 73 75 66 66 69 78 0a 20 |e print |suffix. |
|00005570| 20 20 20 20 6f 66 20 74 | 68 65 20 6c 61 73 74 20 | of t|he last |
|00005580| 73 75 62 73 74 69 74 75 | 74 69 6f 6e 20 54 68 65 |substitu|tion The|
|00005590| 20 63 75 72 72 65 6e 74 | 20 61 64 64 72 65 73 73 | current| address|
|000055a0| 20 69 73 20 73 65 74 20 | 74 6f 20 74 68 65 20 6c | is set |to the l|
|000055b0| 61 73 74 0a 20 20 20 20 | 20 6c 69 6e 65 20 61 66 |ast. | line af|
|000055c0| 66 65 63 74 65 64 2e 0a | 0a 60 28 2e 2c 2e 29 74 |fected..|.`(.,.)t|
|000055d0| 28 2e 29 27 0a 20 20 20 | 20 20 43 6f 70 69 65 73 |(.)'. | Copies|
|000055e0| 20 28 69 2e 65 2e 2c 20 | 74 72 61 6e 73 66 65 72 | (i.e., |transfer|
|000055f0| 73 29 20 74 68 65 20 61 | 64 64 72 65 73 73 65 64 |s) the a|ddressed|
|00005600| 20 6c 69 6e 65 73 20 74 | 6f 20 61 66 74 65 72 20 | lines t|o after |
|00005610| 74 68 65 0a 20 20 20 20 | 20 72 69 67 68 74 2d 68 |the. | right-h|
|00005620| 61 6e 64 20 64 65 73 74 | 69 6e 61 74 69 6f 6e 20 |and dest|ination |
|00005630| 61 64 64 72 65 73 73 2c | 20 77 68 69 63 68 20 6d |address,| which m|
|00005640| 61 79 20 62 65 20 74 68 | 65 20 61 64 64 72 65 73 |ay be th|e addres|
|00005650| 73 20 60 30 27 0a 20 20 | 20 20 20 28 7a 65 72 6f |s `0'. | (zero|
|00005660| 29 2e 20 20 54 68 65 20 | 63 75 72 72 65 6e 74 20 |). The |current |
|00005670| 61 64 64 72 65 73 73 20 | 69 73 20 73 65 74 20 74 |address |is set t|
|00005680| 6f 20 74 68 65 20 6c 61 | 73 74 20 6c 69 6e 65 20 |o the la|st line |
|00005690| 63 6f 70 69 65 64 2e 0a | 0a 60 75 27 0a 20 20 20 |copied..|.`u'. |
|000056a0| 20 20 55 6e 64 6f 65 73 | 20 74 68 65 20 6c 61 73 | Undoes| the las|
|000056b0| 74 20 63 6f 6d 6d 61 6e | 64 20 61 6e 64 20 72 65 |t comman|d and re|
|000056c0| 73 74 6f 72 65 73 20 74 | 68 65 20 63 75 72 72 65 |stores t|he curre|
|000056d0| 6e 74 20 61 64 64 72 65 | 73 73 20 74 6f 20 77 68 |nt addre|ss to wh|
|000056e0| 61 74 0a 20 20 20 20 20 | 69 74 20 77 61 73 20 62 |at. |it was b|
|000056f0| 65 66 6f 72 65 20 74 68 | 65 20 63 6f 6d 6d 61 6e |efore th|e comman|
|00005700| 64 2e 20 20 54 68 65 20 | 67 6c 6f 62 61 6c 20 63 |d. The |global c|
|00005710| 6f 6d 6d 61 6e 64 73 20 | 60 67 27 2c 20 60 47 27 |ommands |`g', `G'|
|00005720| 2c 20 60 76 27 2c 20 61 | 6e 64 0a 20 20 20 20 20 |, `v', a|nd. |
|00005730| 60 56 27 20 61 72 65 20 | 74 72 65 61 74 65 64 20 |`V' are |treated |
|00005740| 61 73 20 61 20 73 69 6e | 67 6c 65 20 63 6f 6d 6d |as a sin|gle comm|
|00005750| 61 6e 64 20 62 79 20 75 | 6e 64 6f 2e 20 20 60 75 |and by u|ndo. `u|
|00005760| 27 20 69 73 20 69 74 73 | 20 6f 77 6e 0a 20 20 20 |' is its| own. |
|00005770| 20 20 69 6e 76 65 72 73 | 65 2e 0a 0a 60 28 31 2c | invers|e...`(1,|
|00005780| 24 29 76 20 2f 50 41 54 | 2f 43 4f 4d 4d 41 4e 44 |$)v /PAT|/COMMAND|
|00005790| 2d 4c 49 53 54 27 0a 20 | 20 20 20 20 41 70 70 6c |-LIST'. | Appl|
|000057a0| 69 65 73 20 43 4f 4d 4d | 41 4e 44 2d 4c 49 53 54 |ies COMM|AND-LIST|
|000057b0| 20 74 6f 20 65 61 63 68 | 20 6f 66 20 74 68 65 20 | to each| of the |
|000057c0| 61 64 64 72 65 73 73 65 | 64 20 6c 69 6e 65 73 20 |addresse|d lines |
|000057d0| 6e 6f 74 20 6d 61 74 63 | 68 69 6e 67 20 61 0a 20 |not matc|hing a. |
|000057e0| 20 20 20 20 72 65 67 75 | 6c 61 72 20 65 78 70 72 | regu|lar expr|
|000057f0| 65 73 73 69 6f 6e 20 52 | 45 2e 20 20 54 68 69 73 |ession R|E. This|
|00005800| 20 69 73 20 73 69 6d 69 | 6c 61 72 20 74 6f 20 74 | is simi|lar to t|
|00005810| 68 65 20 60 67 27 20 63 | 6f 6d 6d 61 6e 64 2e 0a |he `g' c|ommand..|
|00005820| 0a 60 28 31 2c 24 29 56 | 20 2f 52 45 2f 27 0a 20 |.`(1,$)V| /RE/'. |
|00005830| 20 20 20 20 49 6e 74 65 | 72 61 63 74 69 76 65 6c | Inte|ractivel|
|00005840| 79 20 65 64 69 74 73 20 | 74 68 65 20 61 64 64 72 |y edits |the addr|
|00005850| 65 73 73 65 64 20 6c 69 | 6e 65 73 20 6e 6f 74 20 |essed li|nes not |
|00005860| 6d 61 74 63 68 69 6e 67 | 20 61 20 72 65 67 75 6c |matching| a regul|
|00005870| 61 72 0a 20 20 20 20 20 | 65 78 70 72 65 73 73 69 |ar. |expressi|
|00005880| 6f 6e 20 52 45 2e 20 20 | 54 68 69 73 20 69 73 20 |on RE. |This is |
|00005890| 73 69 6d 69 6c 61 72 20 | 74 6f 20 74 68 65 20 60 |similar |to the `|
|000058a0| 47 27 20 63 6f 6d 6d 61 | 6e 64 2e 0a 0a 60 28 31 |G' comma|nd...`(1|
|000058b0| 2c 24 29 77 20 46 49 4c | 45 27 0a 20 20 20 20 20 |,$)w FIL|E'. |
|000058c0| 57 72 69 74 65 73 20 74 | 68 65 20 61 64 64 72 65 |Writes t|he addre|
|000058d0| 73 73 65 64 20 6c 69 6e | 65 73 20 74 6f 20 46 49 |ssed lin|es to FI|
|000058e0| 4c 45 2e 20 20 41 6e 79 | 20 70 72 65 76 69 6f 75 |LE. Any| previou|
|000058f0| 73 20 63 6f 6e 74 65 6e | 74 73 20 6f 66 20 46 49 |s conten|ts of FI|
|00005900| 4c 45 0a 20 20 20 20 20 | 69 73 20 6c 6f 73 74 20 |LE. |is lost |
|00005910| 77 69 74 68 6f 75 74 20 | 77 61 72 6e 69 6e 67 2e |without |warning.|
|00005920| 20 20 49 66 20 74 68 65 | 72 65 20 69 73 20 6e 6f | If the|re is no|
|00005930| 20 64 65 66 61 75 6c 74 | 20 66 69 6c 65 6e 61 6d | default| filenam|
|00005940| 65 2c 20 74 68 65 6e 0a | 20 20 20 20 20 74 68 65 |e, then.| the|
|00005950| 20 64 65 66 61 75 6c 74 | 20 66 69 6c 65 6e 61 6d | default| filenam|
|00005960| 65 20 69 73 20 73 65 74 | 20 74 6f 20 46 49 4c 45 |e is set| to FILE|
|00005970| 2c 20 6f 74 68 65 72 77 | 69 73 65 20 69 74 20 69 |, otherw|ise it i|
|00005980| 73 20 75 6e 63 68 61 6e | 67 65 64 2e 0a 20 20 20 |s unchan|ged.. |
|00005990| 20 20 49 66 20 6e 6f 20 | 66 69 6c 65 6e 61 6d 65 | If no |filename|
|000059a0| 20 69 73 20 73 70 65 63 | 69 66 69 65 64 2c 20 74 | is spec|ified, t|
|000059b0| 68 65 6e 20 74 68 65 20 | 64 65 66 61 75 6c 74 20 |hen the |default |
|000059c0| 66 69 6c 65 6e 61 6d 65 | 20 69 73 20 75 73 65 64 |filename| is used|
|000059d0| 2e 0a 20 20 20 20 20 54 | 68 65 20 63 75 72 72 65 |.. T|he curre|
|000059e0| 6e 74 20 61 64 64 72 65 | 73 73 20 69 73 20 75 6e |nt addre|ss is un|
|000059f0| 63 68 61 6e 67 65 64 2e | 0a 0a 60 28 31 2c 24 29 |changed.|..`(1,$)|
|00005a00| 77 71 20 46 49 4c 45 27 | 0a 20 20 20 20 20 57 72 |wq FILE'|. Wr|
|00005a10| 69 74 65 73 20 74 68 65 | 20 61 64 64 72 65 73 73 |ites the| address|
|00005a20| 65 64 20 6c 69 6e 65 73 | 20 74 6f 20 46 49 4c 45 |ed lines| to FILE|
|00005a30| 2c 20 61 6e 64 20 74 68 | 65 6e 20 65 78 65 63 75 |, and th|en execu|
|00005a40| 74 65 73 20 61 20 60 71 | 27 0a 20 20 20 20 20 63 |tes a `q|'. c|
|00005a50| 6f 6d 6d 61 6e 64 2e 0a | 0a 60 28 31 2c 24 29 77 |ommand..|.`(1,$)w|
|00005a60| 20 21 43 4f 4d 4d 41 4e | 44 27 0a 20 20 20 20 20 | !COMMAN|D'. |
|00005a70| 57 72 69 74 65 73 20 74 | 68 65 20 61 64 64 72 65 |Writes t|he addre|
|00005a80| 73 73 65 64 20 6c 69 6e | 65 73 20 74 6f 20 74 68 |ssed lin|es to th|
|00005a90| 65 20 73 74 61 6e 64 61 | 72 64 20 69 6e 70 75 74 |e standa|rd input|
|00005aa0| 20 6f 66 20 60 21 43 4f | 4d 4d 41 4e 44 27 2c 0a | of `!CO|MMAND',.|
|00005ab0| 20 20 20 20 20 28 73 65 | 65 20 74 68 65 20 60 21 | (se|e the `!|
|00005ac0| 27 20 63 6f 6d 6d 61 6e | 64 20 62 65 6c 6f 77 29 |' comman|d below)|
|00005ad0| 2e 20 20 54 68 65 20 64 | 65 66 61 75 6c 74 20 66 |. The d|efault f|
|00005ae0| 69 6c 65 6e 61 6d 65 20 | 61 6e 64 20 63 75 72 72 |ilename |and curr|
|00005af0| 65 6e 74 0a 20 20 20 20 | 20 61 64 64 72 65 73 73 |ent. | address|
|00005b00| 20 61 72 65 20 75 6e 63 | 68 61 6e 67 65 64 2e 0a | are unc|hanged..|
|00005b10| 0a 60 28 31 2c 24 29 57 | 20 46 49 4c 45 27 0a 20 |.`(1,$)W| FILE'. |
|00005b20| 20 20 20 20 41 70 70 65 | 6e 64 73 20 74 68 65 20 | Appe|nds the |
|00005b30| 61 64 64 72 65 73 73 65 | 64 20 6c 69 6e 65 73 20 |addresse|d lines |
|00005b40| 74 6f 20 74 68 65 20 65 | 6e 64 20 6f 66 20 46 49 |to the e|nd of FI|
|00005b50| 4c 45 2e 20 20 54 68 69 | 73 20 69 73 20 73 69 6d |LE. Thi|s is sim|
|00005b60| 69 6c 61 72 0a 20 20 20 | 20 20 74 6f 20 74 68 65 |ilar. | to the|
|00005b70| 20 60 77 27 20 63 6f 6d | 6d 61 6e 64 2c 20 65 78 | `w' com|mand, ex|
|00005b80| 70 65 63 74 20 74 68 61 | 74 20 74 68 65 20 70 72 |pect tha|t the pr|
|00005b90| 65 76 69 6f 75 73 20 63 | 6f 6e 74 65 6e 74 73 20 |evious c|ontents |
|00005ba0| 6f 66 20 66 69 6c 65 20 | 69 73 0a 20 20 20 20 20 |of file |is. |
|00005bb0| 6e 6f 74 20 63 6c 6f 62 | 62 65 72 65 64 2e 20 20 |not clob|bered. |
|00005bc0| 54 68 65 20 63 75 72 72 | 65 6e 74 20 61 64 64 72 |The curr|ent addr|
|00005bd0| 65 73 73 20 69 73 20 75 | 6e 63 68 61 6e 67 65 64 |ess is u|nchanged|
|00005be0| 2e 0a 0a 60 28 2e 2b 31 | 29 7a 20 4e 27 0a 20 20 |...`(.+1|)z N'. |
|00005bf0| 20 20 20 53 63 72 6f 6c | 6c 73 20 4e 20 6c 69 6e | Scrol|ls N lin|
|00005c00| 65 73 20 61 74 20 61 20 | 74 69 6d 65 20 73 74 61 |es at a |time sta|
|00005c10| 72 74 69 6e 67 20 61 74 | 20 61 64 64 72 65 73 73 |rting at| address|
|00005c20| 65 64 20 6c 69 6e 65 2e | 20 20 49 66 20 4e 20 69 |ed line.| If N i|
|00005c30| 73 20 6e 6f 74 0a 20 20 | 20 20 20 73 70 65 63 69 |s not. | speci|
|00005c40| 66 69 65 64 2c 20 74 68 | 65 6e 20 74 68 65 20 63 |fied, th|en the c|
|00005c50| 75 72 72 65 6e 74 20 77 | 69 6e 64 6f 77 20 73 69 |urrent w|indow si|
|00005c60| 7a 65 20 69 73 20 75 73 | 65 64 2e 20 20 54 68 65 |ze is us|ed. The|
|00005c70| 20 63 75 72 72 65 6e 74 | 0a 20 20 20 20 20 61 64 | current|. ad|
|00005c80| 64 72 65 73 73 20 69 73 | 20 73 65 74 20 74 6f 20 |dress is| set to |
|00005c90| 74 68 65 20 6c 61 73 74 | 20 6c 69 6e 65 20 70 72 |the last| line pr|
|00005ca0| 69 6e 74 65 64 2e 0a 0a | 60 21 20 43 4f 4d 4d 41 |inted...|`! COMMA|
|00005cb0| 4e 44 27 0a 20 20 20 20 | 20 45 78 65 63 75 74 65 |ND'. | Execute|
|00005cc0| 73 20 43 4f 4d 4d 41 4e | 44 20 76 69 61 20 60 73 |s COMMAN|D via `s|
|00005cd0| 68 20 28 31 29 27 2e 20 | 20 49 66 20 74 68 65 20 |h (1)'. | If the |
|00005ce0| 66 69 72 73 74 20 63 68 | 61 72 61 63 74 65 72 20 |first ch|aracter |
|00005cf0| 6f 66 20 43 4f 4d 4d 41 | 4e 44 0a 20 20 20 20 20 |of COMMA|ND. |
|00005d00| 69 73 20 60 21 27 2c 20 | 74 68 65 6e 20 69 74 20 |is `!', |then it |
|00005d10| 69 73 20 72 65 70 6c 61 | 63 65 64 20 62 79 20 74 |is repla|ced by t|
|00005d20| 65 78 74 20 6f 66 20 74 | 68 65 20 70 72 65 76 69 |ext of t|he previ|
|00005d30| 6f 75 73 20 60 21 43 4f | 4d 4d 41 4e 44 27 2e 0a |ous `!CO|MMAND'..|
|00005d40| 20 20 20 20 20 60 65 64 | 27 20 64 6f 65 73 20 6e | `ed|' does n|
|00005d50| 6f 74 20 70 72 6f 63 65 | 73 73 20 43 4f 4d 4d 41 |ot proce|ss COMMA|
|00005d60| 4e 44 20 66 6f 72 20 62 | 61 63 6b 73 6c 61 73 68 |ND for b|ackslash|
|00005d70| 20 28 60 5c 27 29 20 65 | 73 63 61 70 65 73 2e 0a | (`\') e|scapes..|
|00005d80| 20 20 20 20 20 48 6f 77 | 65 76 65 72 2c 20 61 6e | How|ever, an|
|00005d90| 20 75 6e 65 73 63 61 70 | 65 64 20 60 25 27 20 69 | unescap|ed `%' i|
|00005da0| 73 20 72 65 70 6c 61 63 | 65 64 20 62 79 20 74 68 |s replac|ed by th|
|00005db0| 65 20 64 65 66 61 75 6c | 74 20 66 69 6c 65 6e 61 |e defaul|t filena|
|00005dc0| 6d 65 2e 0a 20 20 20 20 | 20 57 68 65 6e 20 74 68 |me.. | When th|
|00005dd0| 65 20 73 68 65 6c 6c 20 | 72 65 74 75 72 6e 73 20 |e shell |returns |
|00005de0| 66 72 6f 6d 20 65 78 65 | 63 75 74 69 6f 6e 2c 20 |from exe|cution, |
|00005df0| 61 20 60 21 27 20 69 73 | 20 70 72 69 6e 74 65 64 |a `!' is| printed|
|00005e00| 20 74 6f 20 74 68 65 0a | 20 20 20 20 20 73 74 61 | to the.| sta|
|00005e10| 6e 64 61 72 64 20 6f 75 | 74 70 75 74 2e 20 20 54 |ndard ou|tput. T|
|00005e20| 68 65 20 63 75 72 72 65 | 6e 74 20 6c 69 6e 65 20 |he curre|nt line |
|00005e30| 69 73 20 75 6e 63 68 61 | 6e 67 65 64 2e 0a 0a 60 |is uncha|nged...`|
|00005e40| 28 2e 2c 2e 29 23 27 0a | 20 20 20 20 20 42 65 67 |(.,.)#'.| Beg|
|00005e50| 69 6e 73 20 61 20 63 6f | 6d 6d 65 6e 74 3b 20 20 |ins a co|mment; |
|00005e60| 74 68 65 20 72 65 73 74 | 20 6f 66 20 74 68 65 20 |the rest| of the |
|00005e70| 6c 69 6e 65 2c 20 75 70 | 20 74 6f 20 61 20 6e 65 |line, up| to a ne|
|00005e80| 77 6c 69 6e 65 2c 20 69 | 73 0a 20 20 20 20 20 69 |wline, i|s. i|
|00005e90| 67 6e 6f 72 65 64 2e 20 | 20 49 66 20 61 20 6c 69 |gnored. | If a li|
|00005ea0| 6e 65 20 61 64 64 72 65 | 73 73 20 66 6f 6c 6c 6f |ne addre|ss follo|
|00005eb0| 77 65 64 20 62 79 20 61 | 20 73 65 6d 69 2d 63 6f |wed by a| semi-co|
|00005ec0| 6c 6f 6e 20 69 73 20 67 | 69 76 65 6e 2c 0a 20 20 |lon is g|iven,. |
|00005ed0| 20 20 20 74 68 65 6e 20 | 74 68 65 20 63 75 72 72 | then |the curr|
|00005ee0| 65 6e 74 20 61 64 64 72 | 65 73 73 20 69 73 20 73 |ent addr|ess is s|
|00005ef0| 65 74 20 74 6f 20 74 68 | 61 74 20 61 64 64 72 65 |et to th|at addre|
|00005f00| 73 73 2e 20 20 4f 74 68 | 65 72 77 69 73 65 2c 20 |ss. Oth|erwise, |
|00005f10| 74 68 65 0a 20 20 20 20 | 20 63 75 72 72 65 6e 74 |the. | current|
|00005f20| 20 61 64 64 72 65 73 73 | 20 69 73 20 75 6e 63 68 | address| is unch|
|00005f30| 61 6e 67 65 64 2e 0a 0a | 60 28 24 29 3d 27 0a 20 |anged...|`($)='. |
|00005f40| 20 20 20 20 50 72 69 6e | 74 73 20 74 68 65 20 6c | Prin|ts the l|
|00005f50| 69 6e 65 20 6e 75 6d 62 | 65 72 20 6f 66 20 74 68 |ine numb|er of th|
|00005f60| 65 20 61 64 64 72 65 73 | 73 65 64 20 6c 69 6e 65 |e addres|sed line|
|00005f70| 2e 0a 0a 60 28 2e 2b 31 | 29 6e 65 77 6c 69 6e 65 |...`(.+1|)newline|
|00005f80| 27 0a 20 20 20 20 20 50 | 72 69 6e 74 73 20 74 68 |'. P|rints th|
|00005f90| 65 20 61 64 64 72 65 73 | 73 65 64 20 6c 69 6e 65 |e addres|sed line|
|00005fa0| 2c 20 61 6e 64 20 73 65 | 74 73 20 74 68 65 20 63 |, and se|ts the c|
|00005fb0| 75 72 72 65 6e 74 20 61 | 64 64 72 65 73 73 20 74 |urrent a|ddress t|
|00005fc0| 6f 20 74 68 61 74 0a 20 | 20 20 20 20 6c 69 6e 65 |o that. | line|
|00005fd0| 2e 0a 0a 1f 0a 46 69 6c | 65 3a 20 65 64 2e 69 6e |.....Fil|e: ed.in|
|00005fe0| 66 6f 2c 20 20 4e 6f 64 | 65 3a 20 4c 69 6d 69 74 |fo, Nod|e: Limit|
|00005ff0| 61 74 69 6f 6e 73 2c 20 | 20 4e 65 78 74 3a 20 44 |ations, | Next: D|
|00006000| 69 61 67 6e 6f 73 74 69 | 63 73 2c 20 20 50 72 65 |iagnosti|cs, Pre|
|00006010| 76 3a 20 43 6f 6d 6d 61 | 6e 64 73 2c 20 20 55 70 |v: Comma|nds, Up|
|00006020| 3a 20 54 6f 70 0a 0a 4c | 69 6d 69 74 61 74 69 6f |: Top..L|imitatio|
|00006030| 6e 73 0a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 0a 0a |ns.*****|******..|
|00006040| 20 20 20 54 68 65 20 62 | 75 66 66 65 72 20 66 69 | The b|uffer fi|
|00006050| 6c 65 73 20 61 72 65 20 | 6b 65 70 74 20 69 6e 20 |les are |kept in |
|00006060| 60 2f 74 6d 70 2f 65 64 | 2e 2a 27 2e 20 20 49 66 |`/tmp/ed|.*'. If|
|00006070| 20 74 68 65 20 74 65 72 | 6d 69 6e 61 6c 20 68 61 | the ter|minal ha|
|00006080| 6e 67 73 20 75 70 2c 0a | 60 65 64 27 20 61 74 74 |ngs up,.|`ed' att|
|00006090| 65 6d 70 74 73 20 74 6f | 20 77 72 69 74 65 20 74 |empts to| write t|
|000060a0| 68 65 20 62 75 66 66 65 | 72 20 74 6f 20 66 69 6c |he buffe|r to fil|
|000060b0| 65 20 60 65 64 2e 68 75 | 70 27 2e 0a 0a 20 20 20 |e `ed.hu|p'... |
|000060c0| 60 65 64 27 20 70 72 6f | 63 65 73 73 65 73 20 46 |`ed' pro|cesses F|
|000060d0| 49 4c 45 20 61 72 67 75 | 6d 65 6e 74 73 20 66 6f |ILE argu|ments fo|
|000060e0| 72 20 62 61 63 6b 73 6c | 61 73 68 20 65 73 63 61 |r backsl|ash esca|
|000060f0| 70 65 73 2c 20 69 2e 65 | 2e 2c 20 69 6e 20 61 0a |pes, i.e|., in a.|
|00006100| 66 69 6c 65 6e 61 6d 65 | 2c 20 61 6e 79 20 63 68 |filename|, any ch|
|00006110| 61 72 61 63 74 65 72 73 | 20 70 72 65 63 65 64 65 |aracters| precede|
|00006120| 64 20 62 79 20 61 20 62 | 61 63 6b 73 6c 61 73 68 |d by a b|ackslash|
|00006130| 20 28 60 5c 27 29 20 61 | 72 65 20 69 6e 74 65 72 | (`\') a|re inter|
|00006140| 70 72 65 74 65 64 0a 6c | 69 74 65 72 61 6c 6c 79 |preted.l|iterally|
|00006150| 2e 0a 0a 20 20 20 49 66 | 20 61 20 74 65 78 74 20 |... If| a text |
|00006160| 28 6e 6f 6e 2d 62 69 6e | 61 72 79 29 20 66 69 6c |(non-bin|ary) fil|
|00006170| 65 20 69 73 20 6e 6f 74 | 20 74 65 72 6d 69 6e 61 |e is not| termina|
|00006180| 74 65 64 20 62 79 20 61 | 20 6e 65 77 6c 69 6e 65 |ted by a| newline|
|00006190| 20 63 68 61 72 61 63 74 | 65 72 2c 0a 74 68 65 6e | charact|er,.then|
|000061a0| 20 60 65 64 27 20 61 70 | 70 65 6e 64 73 20 6f 6e | `ed' ap|pends on|
|000061b0| 65 20 6f 6e 20 72 65 61 | 64 69 6e 67 2f 77 72 69 |e on rea|ding/wri|
|000061c0| 74 69 6e 67 20 69 74 2e | 20 20 49 6e 20 74 68 65 |ting it.| In the|
|000061d0| 20 63 61 73 65 20 6f 66 | 20 61 20 62 69 6e 61 72 | case of| a binar|
|000061e0| 79 0a 66 69 6c 65 2c 20 | 60 65 64 27 20 64 6f 65 |y.file, |`ed' doe|
|000061f0| 73 20 6e 6f 74 20 61 70 | 70 65 6e 64 20 61 20 6e |s not ap|pend a n|
|00006200| 65 77 6c 69 6e 65 20 6f | 6e 20 72 65 61 64 69 6e |ewline o|n readin|
|00006210| 67 2f 77 72 69 74 69 6e | 67 2e 0a 0a 20 20 20 50 |g/writin|g... P|
|00006220| 65 72 20 6c 69 6e 65 20 | 6f 76 65 72 68 65 61 64 |er line |overhead|
|00006230| 3a 20 34 20 60 69 6e 74 | 27 73 2e 0a 0a 1f 0a 46 |: 4 `int|'s.....F|
|00006240| 69 6c 65 3a 20 65 64 2e | 69 6e 66 6f 2c 20 20 4e |ile: ed.|info, N|
|00006250| 6f 64 65 3a 20 44 69 61 | 67 6e 6f 73 74 69 63 73 |ode: Dia|gnostics|
|00006260| 2c 20 20 50 72 65 76 3a | 20 4c 69 6d 69 74 61 74 |, Prev:| Limitat|
|00006270| 69 6f 6e 73 2c 20 20 55 | 70 3a 20 54 6f 70 0a 0a |ions, U|p: Top..|
|00006280| 44 69 61 67 6e 6f 73 74 | 69 63 73 0a 2a 2a 2a 2a |Diagnost|ics.****|
|00006290| 2a 2a 2a 2a 2a 2a 2a 0a | 0a 20 20 20 57 68 65 6e |*******.|. When|
|000062a0| 20 61 6e 20 65 72 72 6f | 72 20 6f 63 63 75 72 73 | an erro|r occurs|
|000062b0| 2c 20 60 65 64 27 20 70 | 72 69 6e 74 73 20 61 20 |, `ed' p|rints a |
|000062c0| 60 3f 27 20 61 6e 64 20 | 65 69 74 68 65 72 20 72 |`?' and |either r|
|000062d0| 65 74 75 72 6e 73 20 74 | 6f 0a 63 6f 6d 6d 61 6e |eturns t|o.comman|
|000062e0| 64 20 6d 6f 64 65 20 6f | 72 20 65 78 69 74 73 20 |d mode o|r exits |
|000062f0| 69 66 20 69 74 73 20 69 | 6e 70 75 74 20 69 73 20 |if its i|nput is |
|00006300| 66 72 6f 6d 20 61 20 73 | 63 72 69 70 74 2e 20 20 |from a s|cript. |
|00006310| 41 6e 20 65 78 70 6c 61 | 6e 61 74 69 6f 6e 20 6f |An expla|nation o|
|00006320| 66 0a 74 68 65 20 6c 61 | 73 74 20 65 72 72 6f 72 |f.the la|st error|
|00006330| 20 63 61 6e 20 62 65 20 | 70 72 69 6e 74 65 64 20 | can be |printed |
|00006340| 77 69 74 68 20 74 68 65 | 20 60 68 27 20 28 68 65 |with the| `h' (he|
|00006350| 6c 70 29 20 63 6f 6d 6d | 61 6e 64 2e 0a 0a 20 20 |lp) comm|and... |
|00006360| 20 53 69 6e 63 65 20 74 | 68 65 20 60 67 27 20 28 | Since t|he `g' (|
|00006370| 67 6c 6f 62 61 6c 29 20 | 63 6f 6d 6d 61 6e 64 20 |global) |command |
|00006380| 20 6d 61 73 6b 73 20 61 | 6e 79 20 65 72 72 6f 72 | masks a|ny error|
|00006390| 73 20 66 72 6f 6d 20 66 | 61 69 6c 65 64 0a 73 65 |s from f|ailed.se|
|000063a0| 61 72 63 68 65 73 20 61 | 6e 64 20 73 75 62 73 74 |arches a|nd subst|
|000063b0| 69 74 75 74 69 6f 6e 73 | 2c 20 69 74 20 63 61 6e |itutions|, it can|
|000063c0| 20 62 65 20 75 73 65 64 | 20 74 6f 20 70 65 72 66 | be used| to perf|
|000063d0| 6f 72 6d 20 63 6f 6e 64 | 69 74 69 6f 6e 61 6c 0a |orm cond|itional.|
|000063e0| 6f 70 65 72 61 74 69 6f | 6e 73 20 69 6e 20 73 63 |operatio|ns in sc|
|000063f0| 72 69 70 74 73 3b 20 65 | 2e 67 2e 2c 0a 0a 20 20 |ripts; e|.g.,.. |
+--------+-------------------------+-------------------------+--------+--------+
Only 25.0 KB of data is shown above.