BSD 4_1_snap development
[unix-history] / usr / lib / learn / editor / L15.1a
CommitLineData
3eb5d546
C
1#print
2So far you only know how to copy and print existing files
3in the editor, and not how to get started from scratch.
4The 'a' (append) command lets you type in new text.
5For example, the sequence
6 ed file
7 a
8 this is a new line of text
9 .
10 w
11 q
12will append the line
13 this is a new line of text
14to the editor buffer, and then write it on "file".
15(If "file" doesn't already exist, the editor will
16warn you, but it's not an error.)
17Note that the material being added ends with the
18line that just contains a single '.' and that normal
19editor commands then resume. Following this pattern,
20make a file named "pres" that contains the
21line
22
23franklin delano roosevelt
24
25and, after you have written it with a 'w' command,
26and done your 'q', try saying "cat pres" to check that
27you did it right.
28Then type "ready".
29#create Ref
30franklin delano roosevelt
31#user
32#cmp pres Ref
33#log
34#next
3515.1b 10