📄 man.sh
字号:
echo x - ctags.mansed '/^X/s///' > ctags.man << '/'X.TH CTAGS 1X.SH NAMEXctags - Generates "tags" and (optionally) "refs" filesX.SH SYNOPSISX\fBctags\fP [\fB-stvra\fP] \fIfilesnames\fP...X.SH DESCRIPTIONX\fIctags\fP generates the "tags" and "refs" filesXfrom a group of C source files.XThe "tags" file is used by Elvis' ":tag" command,Xcontrol-] command,Xand -t option.XThe "refs" file is sometimes used by the \fIref(1)\fP program.X.PPXEach C source file is scanned for #define statements andXglobal function definitions.XThe name of the macro or function becomes the name of a tag.XFor each tag, a line is added to the "tags" file which contains:X.RSX.nfX - the name of the tagX - a tab characterX - the name of the file containing the tagX - a tab characterX - a way to find the particular line within the file.X.REX.fiX.PPXThe filenames list will typically be the names of all C sourceXfiles in the current directory, like this:X.RSX.nfX$ ctags -stv *.[ch]X.REX.fiX.SH OPTIONSX.IP \fB-t\fRXInclude typedefs.XA tag will be generated for each user-defined type.XAlso tags will be generated for struct and enum names.XTypes are considered to be global if they are defined in a header file,Xand static if they are defined in a C source file.X.IP \fB-v\fRXInclude variable declarations.XA tag will be generated for each variable, except for those that are declaredXinside the body of a function.X.IP \fB-s\fRXInclude static tags.X\fICtags\fR will normally put global tags in the "tags" file, and silently ignoreXthe static tags.XThis flag causes both global and static tags to be added.XThe name of a static tag is generated by prefixing the name of the declaredXitem with the name of the file where it is defined, with a colon in between.XFor example, "static foo(){}" in "bar.c" results in a tag named "bar.c:foo".X.IP \fB-r\fPXThis causes \fIctags\fP to generate both "tags" and "refs".XWithout \fB-r\fP, it would only generate "tags".X.IP \fB-a\fRXAppend to "tags", and maybe "refs".XNormally, \fIctags\fR overwrites these files each time it is invoked.XThis flag is useful when you have to many files in the current directoryXfor you to list them on a single command-line;Xit allows you to split the arguments among several invocations.X.SH FILESX.IP tagsXA cross-reference that lists each tag name, the name of the source file thatXcontains it, and a way to locate a particular line in the source file.X.IP refsXThe "refs" file contains the definitions for each tag in the "tags" file,Xand very little else.XThis file can be useful, for example, when licensing restrictions preventXyou from making the source code to the standard C library readable by everybody,Xbut you still everybody to know what arguments the library functions need.X.SH BUGSX.PPX\fIctags\fR is sensitive to indenting and line breaks.XConsequently, it might not discover all of the tags in a file thatXis formatted in an unusual way.X.SH "SEE ALSO"Xelvis(1), refs(1)X.SH AUTHORX.nfXSteve KirkendallXkirkenda@cs.pdx.eduX.fi/echo x - elvis.mansed '/^X/s///' > elvis.man << '/'X.TH ELVIS 1X.SH NAMEXelvis, ex, vi, view, input - The editorX.SH SYNOPSISX\fBelvis\fP [\fIflags\fP] [\fB+\fP\fIcmd\fP] [\fIfiles\fP...]X.SH DESCRIPTIONX\fIElvis\fP is a text editor which emulates \fIvi\fP/\fIex\fP.X.PPXOn systems which pass the program name as an argument, such as Unix and Minix,Xyou may also install \fIelvis\fP under the names "ex", "vi", "view", and "input".XThese extra names would normally be links to elvis;Xsee the "ln" shell command.X.PPXWhen \fIelvis\fP is invoked as "vi",Xit behaves exactly as though it was invoked as "elvis".XHowever, if you invoke \fIelvis\fP as "view",Xthen the readonly option is set as though you had given it the "-R" flag.XIf you invoke \fIelvis\fP as "ex",Xthen \fIelvis\fP will start up in the colon command modeXinstead of the visual command mode,Xas though you had given it the "-e" flag.XIf you invoke \fIelvis\fP as "input" or "edit",Xthen \fIelvis\fP will start up in input mode,Xas though the "-i" flag was given.X.SH OPTIONSX.IP \fB-r\fPXTo the real vi, this flag means that a previous edit should be recovered.X\fIElvis\fP, though, has a separate program, called \fIelvrec(1)\fP, for recoveringXfiles.XWhen you invoke \fIelvis\fP with -r, \fIelvis\fP will tell you to run \fIelvrec\fP.X.IP \fB-R\fPXThis sets the "readonly" option,Xso you won't accidentally overwrite a file.X.IP "\fB-t\fP \fItag\fP"XThis causes \fIelvis\fP to start editing at the given tag.X.IP "\fB-m\fP [\fIfile\fP]"X\fIElvis\fP will search through \fIfile\fP for something that looks likeXan error message from a compiler.XIt will then begin editing the source file that caused the error,Xwith the cursor sitting on the line where the error was detected.XIf you don't explicitly name a \fIfile\fP, then "errlist" is assumed.X.IP \fB-e\fPX\fIElvis\fP will start up in colon command mode.X.IP \fB-v\fPX\fIElvis\fP will start up in visual command mode.X.IP \fB-i\fPX\fIElvis\fP will start up in input mode.X.IP "\fB-w\fR \fIwinsize\fR"XSets the "window" option's value to \fIwinsize\fR.X.IP "\fB+\fP\fIcommand\fP or \fB-c\fP \fIcommand\fP"XIf you use the +\fIcommand\fP parameter,Xthen after the first file is loadedX\fIcommand\fP is executed as an EX command.XA typical example would be "elvis +237 foo",Xwhich would cause \fIelvis\fP to start editing foo andXthen move directly to line 237.XThe "-c \fIcommand\fP" variant was added for UNIX SysV compatibility.X.SH FILESX.IP /tmp/elv*XDuring editing,X\fIelvis\fP stores text in a temporary file.XFor UNIX, this file will usually be stored in the /tmp directory,Xand the first three characters will be "elv".XFor other systems, the temporary files may be stored someplace else;Xsee the version-specific section of the documentation.X.IP tagsXThis is the database used by the \fI:tags\fP command and the \fB-t\fP option.XIt is usually created by the \fIctags(1)\fP program.X.IP ".exrc or elvis.rc"XOn UNIX-like systems, a file called ".exrc" in your home directoryXis executed as a series of \fIex\fR commands.XA file by the same name may be executed in the current directory, too.XOn non-UNIX systems, ".exrc" is usually an invalid file name;Xthere, the initialization file is called "elvis.rc" instead.X.SH "SEE ALSO"Xctags(1), ref(1), virec(1)X.PPX\fIElvis - A Clone of Vi/Ex\fP, the complete \fIelvis\fP documentation.X.SH BUGSXThere is no LISP support.XCertain other features are missing, too.X.PPXAuto-indent mode is not quite compatible with the real vi.XAmong other things, 0^D and ^^D don't do what you might expect.X.PPXLong lines are displayed differently.XThe real vi wraps long lines onto multiple rows of the screen,Xbut \fIelvis\fP scrolls sideways.X.SH AUTHORX.nfXSteve KirkendallXkirkenda@cs.pdx.eduX.fiX.PPXMany other people have worked to port \fIelvis\fP to various operating systems.XTo see who deserves credit, run the \fI:version\fP command from within \fIelvis\fP,Xor look in the system-specific section of the complete documentation./echo x - elvprsv.mansed '/^X/s///' > elvprsv.man << '/'X.TH ELVPRSV 1X.SH NAMEXelvprsv - Preserve the the modified version of a file after a crash.X.SH SYNOPSISX.nfX\fB\fBelvprsv\fP ["-\fIwhy elvis died\fP"] /tmp/\fIfilename\fP...X\fB\fBelvprsv\fP -R /tmp/\fIfilename\fP...X.fiX.SH DESCRIPTIONX.PPX\fIelvprsv\fP preserves your edited text after \fIelvis\fP dies.XThe text can be recovered later, via the \fIelvprsv\fP program.X.PPXFor UNIX-like systems,Xyou should never need to run this program from the command line.XIt is run automatically when \fIelvis\fP is about to die,Xand it should be run (via /etc/rc) when the computer is booted.XTHAT'S ALL!X.PP
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -