1 07/23/75 edm
 2 
 3 Function: creates or edits ASCII segments.
 4 
 5 
 6 Syntax: edm {path}
 7 
 8 
 9 Arguments:  path is the pathname of the segment to be edited.
10 
11 
12 Modes: edm has three modes-- input, edit, and comment.
13 If path was specified and found, edm begins in edit mode;
14 otherwise it begins in input mode.
15 
16 In edit mode, edm accepts and performs edit requests.
17 
18 In input mode, all lines typed are appended to the file until a
19 line consisting of "." is typed, causing return to edit mode.
20 
21 In comment mode, one line at a time of the file is printed without
22 carriage return, and the user may append to the end of the line
23 by typing a continuation, or may type a "." to cause a return to
24 edit mode.
25 
26 
27 Requests: in edit mode the following are valid.
28 .  enter input mode; exit when a line with only "." is typed
29 - N  back up N lines
30 ,  enter "comment" mode; exit when a line with only "." is typed
31 =  print current line number
32 b  go to bottom of file, enter input mode
33 c N /s1/s2/  change all occurrences of string "s1" to "s2" for N lines
34 d N  delete N lines
35 updelete  delete all lines above current line
36 E line  execute "line" as a Multics command line
37 f string  find a line beginning with "string"
38 i line  insert "line" after current line
39 
40 
41 merge path  insert segment "path" after current line
42 move M N  beginning with line M, remove N lines and insert
43           them after the current line.
44 k  enter brief mode (no response after f, n, l, c, s)
45 l string  locate a line containing "string"
46 n N  move down N lines
47 p N  print N lines
48 q  exit from edm (See Notes)
49 qf exit directly from edm with no question
50 r line  replace current line with "line"
51 s N /s1/s2/  same as "c"
52 t  go to top of file
53 v  enter verbose mode (opposite of "k")
54 w path  write edited copy of file into "path" (See Notes)
55 upwrite path  write and delete all lines above current line into "path"
56 
57 
58 Notes:
59 For the "s" and "c" requests, the delimiter may be any character
60 not in the strings s1 and s2; c/a/b/ and cxaxbx work the same.
61 If the first string is empty, characters go in at the front.
62 
63 
64 For the "q" request, if a "w" has not been done since the last
65 change to the text then edm warns the user that changes
66 made may be lost and asks whether the user still
67 wishes to exit. If no changes have been made since
68 the last "w" then the user exits directly.
69 The "qf" request bypasses this check.