diff options
author | Jason McIntyre <jmc@cvs.openbsd.org> | 2004-04-05 10:58:09 +0000 |
---|---|---|
committer | Jason McIntyre <jmc@cvs.openbsd.org> | 2004-04-05 10:58:09 +0000 |
commit | 6599bc487ad75284e3ffffbf0d9d64017841d494 (patch) | |
tree | ee2115fee619a29a05e134541255a2628a7d7e95 | |
parent | da898e6794ef50fe8836f9efe8335a1d3df2358d (diff) |
- fix a macro in e.mac that was causing double blank lines in ASCII output
- add margin when formatting in ASCII
- other small fixes
-rw-r--r-- | bin/ed/USD.doc/09.edtut/e.mac | 4 | ||||
-rw-r--r-- | bin/ed/USD.doc/09.edtut/e0 | 9 | ||||
-rw-r--r-- | bin/ed/USD.doc/09.edtut/e1 | 27 | ||||
-rw-r--r-- | bin/ed/USD.doc/09.edtut/e2 | 14 | ||||
-rw-r--r-- | bin/ed/USD.doc/09.edtut/e3 | 22 | ||||
-rw-r--r-- | bin/ed/USD.doc/09.edtut/e4 | 4 | ||||
-rw-r--r-- | bin/ed/USD.doc/09.edtut/e6 | 10 | ||||
-rw-r--r-- | bin/ed/USD.doc/09.edtut/e7 | 4 |
8 files changed, 44 insertions, 50 deletions
diff --git a/bin/ed/USD.doc/09.edtut/e.mac b/bin/ed/USD.doc/09.edtut/e.mac index 46b4ac70d3d..54eb119970a 100644 --- a/bin/ed/USD.doc/09.edtut/e.mac +++ b/bin/ed/USD.doc/09.edtut/e.mac @@ -1,4 +1,4 @@ -.\" $OpenBSD: e.mac,v 1.1 2003/06/26 15:22:51 mickey Exp $ +.\" $OpenBSD: e.mac,v 1.2 2004/04/05 10:58:08 jmc Exp $ .\" .\" Copyright (C) Caldera International Inc. 2001-2002. .\" All rights reserved. @@ -65,7 +65,7 @@ .DE .bd 1 .tr -- -.if n .ls 2 +.if n .ls 1 .. .hy 14 .\" 2=not last lines; 4= no -xx; 8=no xx- diff --git a/bin/ed/USD.doc/09.edtut/e0 b/bin/ed/USD.doc/09.edtut/e0 index 575f3b2f721..f85668dbc30 100644 --- a/bin/ed/USD.doc/09.edtut/e0 +++ b/bin/ed/USD.doc/09.edtut/e0 @@ -1,4 +1,4 @@ -.\" $OpenBSD: e0,v 1.2 2003/06/26 16:24:16 mickey Exp $ +.\" $OpenBSD: e0,v 1.3 2004/04/05 10:58:08 jmc Exp $ .\" .\" Copyright (C) Caldera International Inc. 2001-2002. .\" All rights reserved. @@ -34,6 +34,10 @@ .\" .\" @(#)e0 8.1 (Berkeley) 8/14/93 .\" +.if n \{\ +.po 5n +.ll 70n +.\} .EH 'USD:9-%''A Tutorial Introduction to the \s-2UNIX\s+2 Text Editor' .OH 'A Tutorial Introduction to the \s-2UNIX\s+2 Text Editor''USD:9-%' .\".RP @@ -60,7 +64,8 @@ Although it does not cover everything, it does discuss enough for most users' day-to-day needs. This includes -printing, appending, changing, deleting, moving and inserting entire lines of text; +printing, appending, changing, deleting, moving, +and inserting entire lines of text; reading and writing files; context searching and line addressing; the substitute command; diff --git a/bin/ed/USD.doc/09.edtut/e1 b/bin/ed/USD.doc/09.edtut/e1 index df74a72ec5f..8691f0eefac 100644 --- a/bin/ed/USD.doc/09.edtut/e1 +++ b/bin/ed/USD.doc/09.edtut/e1 @@ -1,4 +1,4 @@ -.\" $OpenBSD: e1,v 1.3 2003/07/26 20:22:13 jmc Exp $ +.\" $OpenBSD: e1,v 1.4 2004/04/05 10:58:08 jmc Exp $ .\" .\" Copyright (C) Caldera International Inc. 2001-2002. .\" All rights reserved. @@ -47,12 +47,11 @@ using directions provided by a user at a terminal. The text is often a document like this one, -or a program +or a program, or perhaps data for a program. .PP This introduction is meant to simplify learning -.ul -ed. +.UL ed . The recommended way to learn .ul ed @@ -64,12 +63,10 @@ to follow the examples, then to read the description in section I of the .ul .UC UNIX -.ul -Programmer's Manual, +.UL "Programmer's Manual" , all the while experimenting with -.ul -ed. +.UL ed . (Solicitation of advice from experienced users is also useful.) .PP Do the exercises! @@ -104,8 +101,7 @@ of what a file is. For more on that, read .ul .UC UNIX -.ul -for Beginners. +.UL "for Beginners" . .PP You must also know what character to type as the end-of-line on your particular terminal. @@ -157,8 +153,7 @@ is first started, it is rather like working with a blank piece of paper \- there is no text or information present. This must be supplied by the person using -.ul -ed; +.UL ed ; it is usually done by typing in the text, or by reading it into .ul @@ -203,8 +198,7 @@ or typing of messages like ``ready''. by experienced users, but sometimes a hangup for beginners.) .PP The first command is -.ul -append, +.UL append , written as the letter .P1 a @@ -267,12 +261,11 @@ command, and continue typing. Error Messages \- ``?'' .PP If at any time you make an error in the commands you type to -.ul -ed, +.UL ed , it will tell you by typing .P1 ? .P2 This is about as cryptic as it can be, -but with practice, you can usually +but with practice you can usually figure out how you goofed. diff --git a/bin/ed/USD.doc/09.edtut/e2 b/bin/ed/USD.doc/09.edtut/e2 index 25bba42449d..6f6668e731c 100644 --- a/bin/ed/USD.doc/09.edtut/e2 +++ b/bin/ed/USD.doc/09.edtut/e2 @@ -1,4 +1,4 @@ -.\" $OpenBSD: e2,v 1.4 2003/07/27 13:22:12 jmc Exp $ +.\" $OpenBSD: e2,v 1.5 2004/04/05 10:58:08 jmc Exp $ .\" .\" Copyright (C) Caldera International Inc. 2001-2002. .\" All rights reserved. @@ -112,9 +112,9 @@ or .UL % ). At this point your buffer vanishes, with all its text, -which is why you want to write it out before quitting.\(dg +which is why you want to write it out before quitting.** .FS -\(dg Actually, +** Actually, .IT ed will print .UL ? @@ -336,8 +336,8 @@ of it) on the terminal, use the print command .P1 p .P2 -The way this is done is as follows. -Specify the lines where +The way this is done is as follows: +specify the lines where you want printing to begin and where you want it to end, separated by a comma, and followed by the letter @@ -363,7 +363,7 @@ You could use .UL 1,3p as above if you knew there were exactly 3 lines in the buffer. -But in general, you don't +But, in general, you don't know how many there are, so what do you use for the ending line number? .ul @@ -379,7 +379,7 @@ way: This will print .ul all -the lines in the buffer (line 1 to last line.) +the lines in the buffer (line 1 to last line). If you want to stop the printing before it is finished, it can be interrupted with .UC ^C diff --git a/bin/ed/USD.doc/09.edtut/e3 b/bin/ed/USD.doc/09.edtut/e3 index 65ac801e0fe..90096f394fe 100644 --- a/bin/ed/USD.doc/09.edtut/e3 +++ b/bin/ed/USD.doc/09.edtut/e3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: e3,v 1.3 2003/07/26 20:22:13 jmc Exp $ +.\" $OpenBSD: e3,v 1.4 2004/04/05 10:58:08 jmc Exp $ .\" .\" Copyright (C) Caldera International Inc. 2001-2002. .\" All rights reserved. @@ -74,7 +74,7 @@ line number. This most recent line is referred to by the shorthand symbol .P1 -\&\*. (pronounced ``dot''). +\&\*. (pronounced ``dot'') .P2 Dot is a line number in the same way that .UL $ @@ -111,7 +111,7 @@ This means ``print the next line'' and is a handy way to step slowly through a buffer. You can also say .P1 -\&\*.\-1 (or \*.\-1p ) +\&\*.\-1 (or \*.\-1p) .P2 which means ``print the line .ul @@ -147,9 +147,9 @@ If there is one line number given .UL p ), it prints that line (and dot is set there); and if there are two line numbers, it prints all the lines in that range -(and sets dot to the last line printed.) +(and sets dot to the last line printed). If two line numbers are specified -the first can't be bigger than the second (see Exercise 2.) +the first can't be bigger than the second (see Exercise 2). .PP Typing a single return will cause printing of the next line \- it's @@ -175,7 +175,7 @@ d .P2 Except that .UL d -deletes lines instead of printing them; +deletes lines instead of printing them, its action is similar to that of .UL p . The lines to be deleted are specified for @@ -210,7 +210,7 @@ Experiment with .UL e , .UL r , .UL w , -.UL p +.UL p , and .UL d until you are sure that you @@ -221,7 +221,7 @@ line numbers are used. .PP If you are adventurous, try using line numbers with .UL a , -.UL r +.UL r , and .UL w as well. @@ -328,11 +328,9 @@ in .ul all the lines between -.ul -starting-line +.UL starting-line and -.ul -ending-line. +.UL ending-line . Only the first occurrence on each line is changed, however. If you want to change .ul diff --git a/bin/ed/USD.doc/09.edtut/e4 b/bin/ed/USD.doc/09.edtut/e4 index 90efc86af40..582cf57a496 100644 --- a/bin/ed/USD.doc/09.edtut/e4 +++ b/bin/ed/USD.doc/09.edtut/e4 @@ -1,4 +1,4 @@ -.\" $OpenBSD: e4,v 1.2 2003/06/26 16:24:16 mickey Exp $ +.\" $OpenBSD: e4,v 1.3 2004/04/05 10:58:08 jmc Exp $ .\" .\" Copyright (C) Caldera International Inc. 2001-2002. .\" All rights reserved. @@ -239,7 +239,7 @@ of the same string of characters, and scan through it using the same context search. .PP Try using context searches as line numbers for the -substitute, print and delete commands. +substitute, print, and delete commands. (They can also be used with .UL r , diff --git a/bin/ed/USD.doc/09.edtut/e6 b/bin/ed/USD.doc/09.edtut/e6 index 0e18d86a41e..cb54653596d 100644 --- a/bin/ed/USD.doc/09.edtut/e6 +++ b/bin/ed/USD.doc/09.edtut/e6 @@ -1,4 +1,4 @@ -.\" $OpenBSD: e6,v 1.2 2003/06/26 16:24:16 mickey Exp $ +.\" $OpenBSD: e6,v 1.3 2004/04/05 10:58:08 jmc Exp $ .\" .\" Copyright (C) Caldera International Inc. 2001-2002. .\" All rights reserved. @@ -59,8 +59,7 @@ means ``any character,'' not a period, so .P2 means ``a line with an .UL x , -.ul -any character, +.UL "any character" , and a .UL y ,'' .ul @@ -72,15 +71,14 @@ a period, and a A complete list of the special characters that can cause trouble is the following: .P1 -^ \*. $ [ * \e +^ \*. $ [ * \e & .P2 .ul Warning: The backslash character .UL \e is special to -.ul -ed. +.UL ed . For safety's sake, avoid it where possible. If you have to use one of the special characters diff --git a/bin/ed/USD.doc/09.edtut/e7 b/bin/ed/USD.doc/09.edtut/e7 index 0cdd2e819e6..0120f58d57b 100644 --- a/bin/ed/USD.doc/09.edtut/e7 +++ b/bin/ed/USD.doc/09.edtut/e7 @@ -1,4 +1,4 @@ -.\" $OpenBSD: e7,v 1.3 2003/07/26 20:22:13 jmc Exp $ +.\" $OpenBSD: e7,v 1.4 2004/04/05 10:58:08 jmc Exp $ .\" .\" Copyright (C) Caldera International Inc. 2001-2002. .\" All rights reserved. @@ -56,7 +56,7 @@ command may follow any other command (except for .UL e , .UL r , -.UL w +.UL w , and .UL q ). .LP |