⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ex.summary

📁 早期freebsd实现
💻 SUMMARY
📖 第 1 页 / 共 2 页
字号:
.\" Copyright (c) 1980, 1993.\"	The Regents of the University of California.  All rights reserved..\".\" Redistribution and use in source and binary forms, with or without.\" modification, are permitted provided that the following conditions.\" are met:.\" 1. Redistributions of source code must retain the above copyright.\"    notice, this list of conditions and the following disclaimer..\" 2. Redistributions in binary form must reproduce the above copyright.\"    notice, this list of conditions and the following disclaimer in the.\"    documentation and/or other materials provided with the distribution..\" 3. All advertising materials mentioning features or use of this software.\"    must display the following acknowledgement:.\"	This product includes software developed by the University of.\"	California, Berkeley and its contributors..\" 4. Neither the name of the University nor the names of its contributors.\"    may be used to endorse or promote products derived from this software.\"    without specific prior written permission..\".\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION).\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF.\" SUCH DAMAGE..\".\"	@(#)ex.summary	8.1 (Berkeley) 6/8/93.\".ds p \v'-0.2'.\v'+0.2'.ds U \s-2UNIX\s+2.ds c \v'-0.2':\v'+0.2'.nr PO .25i.nr LL 6.75i.lt 6.75i.ll 6.75i.ds CH.ds LF Computing Services, U.C. Berkeley.ds RF April 3, 1979.de SP.sp 1v...nr PI 3n.nr PD 0.ND.ps 12.ft B.ce 1Ex/Edit Command Summary (Version 2.0).ft R.nr VS 11.nr PS 9.nr HM 0.5i.nr CW.2C.PP.I Exand.I editare text editors, used for creatingand modifying files of text on the \*Ucomputer system..I Editis a variant of.I exwith features designed tomake it less complicatedto learn and use.In terms of command syntax and effectthe editors are essentially identical,and this command summary applies to both..PPThe summary is meant as a quick referencefor users already acquaintedwith.I editor \fIex\fP.Fuller explanations of the editors are availablein the documents.IEdit: A Tutorial.R(a self-teaching introduction) and the.IEx Reference Manual.R(the comprehensive reference source forboth \fIedit\fP and \fIex\fP).Both of these writeups are available in theComputing Services Library..PPIn the examples included with thesummary, commands and text entered bythe user are printed in \fBboldface\fR todistinguish them from responses printedby the computer..sp 0.45v.LP.BThe Editor Buffer.PPIn order to perform its tasksthe editor sets aside a temporarywork space,called a \fIbuffer\fR,separate from the user's permanentfile.Before starting to work on an existingfile the editor makes a copy of it in thebuffer, leaving the original untouched.All editing changes are made to thebuffer copy, which must thenbe written back to the permanentfile in order to update theold version.The buffer disappearsat the end of the editing session..sp 0.45v.LP.BEditing: Command and Text Input Modes.PP.RDuring an editing session there aretwo usual modes of operation:\fIcommand\fP mode and \fItext input\fPmode.(This disregards, for the moment,.I openand.I visualmodes, discussed below.)In command mode, the editor issues acolon prompt (:)to show that it is ready toaccept and execute a command.In text input mode, on the other hand, there isno prompt and the editor merely accepts text tobe added to the buffer.Text input mode is initiated by the commands\fIappend\fP, \fIinsert\fP, and \fIchange\fP,and is terminated by typing a period as thefirst and only character on a line..sp 0.45v.LP.BLine Numbers and Command Syntax.PP.RThe editor keeps track of lines of textin the buffer by numbering them consecutivelystarting with 1 and renumberingas lines are added or deleted.At any given time the editor is positionedat one of these lines; this position iscalled the \fIcurrent line\fP.Generally, commands that change thecontents of the buffer print thenew current line at the end of theirexecution..PPMost commands can be preceded by one or twoline-number addresses which indicate the linesto be affected.If one number is given the command operates onthat line only; if two, on an inclusive rangeof lines.Commands that can take line-number prefixes alsoassume default prefixes if none are given.The default assumed by each command is designedto make it convenient to use in many instanceswithout any line-number prefix.For the most part, a command used without aprefix operates on the current line,though exceptions to this rule should be noted.The \fIprint\fP commandby itself, for instance, causesone line, the current line, to beprinted at the terminal..PPThe summary shows the number of line addressesthat can beprefixed to each command as well asthe defaults assumed if they are omitted.For example,.I (.,.)means that up to 2 line-numbers may be given,and that if none is given thecommand operates on the current line.(In the address prefix notation, ``.'' standsfor the current line and ``$'' stands forthe last line of the buffer.)If no such notation appears, noline-number prefix may be used..PPSome commands take trailinginformation;onlythe more important instances of thisare mentioned in the summary..sp 0.25v.LP.BOpen and Visual Modes.PP.RBesides command and text input modes,.I exand.I editprovide on some CRT terminals other modes of editing,.I openand.I visual .In these modes the cursor canbe moved to individual wordsor characters in a line.The commands then given are very differentfrom the standard editor commands; most do not appear on the screen whentyped..IAn Introduction to Display Editing with Vi.Rprovides a full discussion..sp 0.25v.LP.BSpecial Characters.PP.R.fiSome characters take on special meaningswhen used in context searchesand in patterns given to the \fIsubstitute\fP command.For \fIedit\fR, these are ``^'' and ``$'',meaning the beginning and end of a line,respectively..I Exhas the following additional special characters:.B.ce 1\&.     &     *     [     ]     ~.RTo use one of the special characters as itssimple graphic representationrather than with its special meaning,precede it by a backslash (\\).The backslash always has a special meaning..1C.rm LF.rm RF.rm CF.nr FM 0.4.TScp10 cp10 cp10 cp10ltw(1.0i) lt2w(0.40i)fB ltw(3.0i) ltw(1.8i).Name	Abbr	Description	Examples.sp 1.75(.)\fBappend	a	T{Begins text input mode,adding lines to the buffer afterthe line specified. Appending continuesuntil ``.'' is typed alone at thebeginning of a new line, followed bya carriage return. \fI0a\fR placeslines at the beginning of the buffer.T}	T{.nf\fR:\fBaThree lines of textare added to the bufferafter the current line.\*p.R\*c.fiT}.SP\fR(.,.)\fBchange	c	T{Deletes indicated line(s) andinitiates text input mode toreplace them with new text which follows.New text is terminated the same wayas with \fIappend\fR.T}	T{.nf:\fB5,6cLines 5 and 6 aredeleted and replaced bythese three lines.\*p.R\*c.fiT}.SP\fR(.,.)\fBcopy \fIaddr	co	T{Places a copy of the specified linesafter the line indicated by \fIaddr\fR.The example places a copy of lines 8 through12, inclusive, after line 25.T}	T{.nf\fR:\fB8,12co 25\fRLast line copied is printed\fR\*c.fiT}.SP\fR(.,.)\fBdelete	d	T{Removes lines from the bufferand prints the current line after the deletion.T}	T{.nf\fR:\fB13,15d\fRNew current line is printed\*c.fiT}.TE.sp 0.5v.TSltw(1.0i) lt2w(0.40i)fB ltw(3.0i) ltw(1.8i).T{\fBedit \fIfile\fP.br\fBedit! \fIfile\fPT}	T{e.bre!T}	T{.fi\fRClears the editor buffer and thencopies into it the named \fIfile\fR,which becomes the current file.This is a way of shifting to a differentfilewithout leaving the editor.The editor issues a warningmessage if this command is used beforesaving changesmade to the file already in the buffer;using the form \fBe!\fR overrides this protective mechanism.T}	T{.nf\fR:\fBe ch10\fRNo write since last change:\fBe! ch10\fR"ch10" 3 lines, 62 characters\*c.fiT}.SP\fBfile \fIname\fR	f	T{\fRIf followed by a \fIname\fR, renamesthe current file to \fIname\fR.If used without \fIname\fR, printsthe name of the current file.T}	T{.nf\fR:\fBf ch9\fR"ch9" [Modified] 3 lines ...:\fBf

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -