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

📄 ctags.html

📁 ctags的最新版5.7,可以比较5.6版看看,免费下载
💻 HTML
📖 第 1 页 / 共 5 页
字号:
<!-- Creator     : groff version 1.19.1 --><!-- CreationDate: Tue Sep  4 23:16:17 2007 --><!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN""http://www.w3.org/TR/html4/loose.dtd"><html><head><meta name="generator" content="groff -Thtml, see www.gnu.org"><meta http-equiv="Content-Type" content="text/html; charset=US-ASCII"><meta name="Content-Style" content="text/css"><title>CTAGS</title></head><body><h1 align=center>CTAGS</h1><a href="#NAME">NAME</a><br><a href="#SYNOPSIS">SYNOPSIS</a><br><a href="#DESCRIPTION">DESCRIPTION</a><br><a href="#SOURCE FILES">SOURCE FILES</a><br><a href="#OPTIONS">OPTIONS</a><br><a href="#OPERATIONAL DETAILS">OPERATIONAL DETAILS</a><br><a href="#TAG FILE FORMAT">TAG FILE FORMAT</a><br><a href="#HOW TO USE WITH VI">HOW TO USE WITH VI</a><br><a href="#HOW TO USE WITH GNU EMACS">HOW TO USE WITH GNU EMACS</a><br><a href="#HOW TO USE WITH NEDIT">HOW TO USE WITH NEDIT</a><br><a href="#CAVEATS">CAVEATS</a><br><a href="#BUGS">BUGS</a><br><a href="#ENVIRONMENT VARIABLES">ENVIRONMENT VARIABLES</a><br><a href="#FILES">FILES</a><br><a href="#SEE ALSO">SEE ALSO</a><br><a href="#AUTHOR">AUTHOR</a><br><a href="#MOTIVATION">MOTIVATION</a><br><a href="#CREDITS">CREDITS</a><br><hr><a name="NAME"></a><h2>NAME</h2><!-- INDENTATION --><table width="100%" border=0 rules="none" frame="void"       cols="2" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="11%"></td><td width="89%"><p>ctags &minus; Generate tag files for source code</p></td></table><a name="SYNOPSIS"></a><h2>SYNOPSIS</h2><!-- INDENTATION --><table width="100%" border=0 rules="none" frame="void"       cols="2" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="11%"></td><td width="89%"><p><b>ctags</b> [<b>options</b>] [<i>file(s)</i>]</p></td></table><!-- INDENTATION --><table width="100%" border=0 rules="none" frame="void"       cols="2" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="11%"></td><td width="89%"><p><b>etags</b> [<b>options</b>] [<i>file(s)</i>]</p></td></table><a name="DESCRIPTION"></a><h2>DESCRIPTION</h2><!-- INDENTATION --><table width="100%" border=0 rules="none" frame="void"       cols="2" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="11%"></td><td width="89%"><p>The <b>ctags</b> and <b>etags</b> programs (hereinaftercollectively referred to as <b>ctags</b>, except wheredistinguished) generate an index (or &quot;tag&quot;) filefor a variety of language objects found in <i>file(s)</i>.This tag file allows these items to be quickly and easilylocated by a text editor or other utility. A &quot;tag&quot;signifies a language object for which an index entry isavailable (or, alternatively, the index entry created forthat object).</p><!-- INDENTATION --><p>Alternatively, <b>ctags</b> can generate a crossreference file which lists, in human readable form,information about the various source objects found in a setof language files.</p><!-- INDENTATION --><p>Tag index files are supported by numerous editors, whichallow the user to locate the object associated with a nameappearing in a source file and jump to the file and linewhich defines the name. Those known about at the time ofthis release are:</p></td></table><!-- INDENTATION --><table width="100%" border=0 rules="none" frame="void"       cols="2" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="17%"></td><td width="83%"><p><b>Vi</b>(1) and its derivatives (e.g. Elvis, Vim, Vile,Lemmy), <b>CRiSP</b>, <b>Emacs</b>, <b>FTE</b> (Folding TextEditor), <b>JED</b>, <b>jEdit</b>, <b>Mined</b>,<b>NEdit</b> (Nirvana Edit), <b>TSE</b> (The SemWareEditor), <b>UltraEdit</b>, <b>WorkSpace</b>, <b>X2</b>,<b>Zeus</b></p></td></table><!-- INDENTATION --><table width="100%" border=0 rules="none" frame="void"       cols="2" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="11%"></td><td width="89%"><p><b>Ctags</b> is capable of generating different kinds oftags for each of many different languages. For a completelist of supported languages, the names by which they arerecognized, and the kinds of tags which are generated foreach, see the <b>&minus;&minus;list&minus;languages</b> and<b>&minus;&minus;list&minus;kinds</b> options.</p></td></table><a name="SOURCE FILES"></a><h2>SOURCE FILES</h2><!-- INDENTATION --><table width="100%" border=0 rules="none" frame="void"       cols="2" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="11%"></td><td width="89%"><p>Unless the <b>&minus;&minus;language&minus;force</b>option is specified, the language of each source file isautomatically selected based upon a mapping of file names tolanguages. The mappings in effect for each language may bedisplay using the <b>&minus;&minus;list&minus;maps</b>option and may be changed using the<b>&minus;&minus;langmap</b> option. On platforms whichsupport it, if the name of a file is not mapped to alanguage and the file is executable, the first line of thefile is checked to see if the file is a &quot;#!&quot;script for a recognized language.</p><!-- INDENTATION --><p>By default, all other files names are ignored. Thispermits running <b>ctags</b> on all files in either a singledirectory (e.g. &quot;ctags *&quot;), or on all files in anentire source directory tree (e.g. &quot;ctags&minus;R&quot;), since only those files whose names aremapped to languages will be scanned.</p><!-- INDENTATION --><p>[The reason that .h extensions are mapped to C++ filesrather than C files is because it is common to use .hextensions in C++, and no harm results in treating them asC++ files.]</p></td></table><a name="OPTIONS"></a><h2>OPTIONS</h2><!-- INDENTATION --><table width="100%" border=0 rules="none" frame="void"       cols="2" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="11%"></td><td width="89%"><p>Despite the wealth of available options, defaults are setso that <b>ctags</b> is most commonly executed without anyoptions (e.g. &quot;ctags *&quot;, or &quot;ctags&minus;R&quot;), which will create a tag file in the currentdirectory for all recognized source files. The optionsdescribed below are provided merely to allow customtailoring to meet special needs.</p><!-- INDENTATION --><p>Note that spaces separating the single-letter optionsfrom their parameters are optional.</p><!-- INDENTATION --><p>Note also that the boolean parameters to the long formoptions (those beginning with &quot;&minus;&minus;&quot; andthat take a &quot;<i>[=yes</i>|<i>no]</i>&quot; parameter)may be omitted, in which case &quot;<b>=</b><i>yes</i>&quot;is implied. (e.g. <b>&minus;&minus;sort</b> is equivalent to<b>&minus;&minus;sort</b>=<i>yes</i>). Note further that&quot;=<i>1</i>&quot; and &quot;=<i>on</i>&quot; areconsidered synonyms for &quot;=<i>yes</i>&quot;, and that&quot;=<i>0</i>&quot; and &quot;=<i>off</i>&quot; areconsidered synonyms for &quot;=<i>no</i>&quot;.</p><!-- INDENTATION --><p>Some options are either ignored or useful only when usedwhile running in etags mode (see <b>&minus;e</b> option).Such options will be noted.</p><!-- INDENTATION --><p>Most options may appear anywhere on the command line,affecting only those files which follow the option. A fewoptions, however, must appear before the first file name andwill be noted as such.</p><!-- INDENTATION --><p>Options taking language names will accept those names ineither upper or lower case. See the<b>&minus;&minus;list&minus;languages</b> option for acomplete list of the built-in language names.</p></td></table><!-- TABS --><table width="100%" border=0 rules="none" frame="void"       cols="4" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="11%"></td><td width="3%"><p><b>&minus;a</b></p></td><td width="4%"></td><td width="82%"><p>Equivalent to <b>&minus;&minus;append</b>.</p></td><tr valign="top" align="left"><td width="11%"></td><td width="3%"><p><b>&minus;B</b></p></td><td width="4%"></td><td width="82%"><p>Use backward searching patterns (e.g. ?pattern?).[Ignored in etags mode]</p></td><tr valign="top" align="left"><td width="11%"></td><td width="3%"><p><b>&minus;e</b></p></td><td width="4%"></td><td width="82%"><p>Enable etags mode, which will create a tag file for usewith the Emacs editor. Alternatively, if <b>ctags</b> isinvoked by a name containing the string &quot;etags&quot;(either by renaming, or creating a link to, the executable),etags mode will be enabled. This option must appear beforethe first file name.</p></td></table><!-- INDENTATION --><table width="100%" border=0 rules="none" frame="void"       cols="2" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="11%"></td><td width="89%"><p><b>&minus;f</b> <i>tagfile</i></p></td></table><!-- INDENTATION --><table width="100%" border=0 rules="none" frame="void"       cols="2" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="18%"></td><td width="82%"><p>Use the name specified by <i>tagfile</i> for the tag file(default is &quot;tags&quot;, or &quot;TAGS&quot; whenrunning in etags mode). If <i>tagfile</i> is specified as&quot;&minus;&quot;, then the tag file is written tostandard output instead. <b>Ctags</b> will stubbornly refuseto take orders if <i>tagfile</i> exists and its first linecontains something other than a valid tags line. This willsave your neck if you mistakenly type &quot;ctags &minus;f*.c&quot;, which would otherwise overwrite your first C filewith the tags generated by the rest! It will also refuse toaccept a multi-character file name which begins with a&rsquo;&minus;&rsquo; (dash) character, since this mostlikely means that you left out the tag file name and thisoption tried to grab the next option as the file name. Ifyou really want to name your output tag file&quot;&minus;ugly&quot;, specify it as&quot;./&minus;ugly&quot;. This option must appear beforethe first file name. If this option is specified more thanonce, only the last will apply.</p></td></table><!-- TABS --><table width="100%" border=0 rules="none" frame="void"       cols="4" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="11%"></td><td width="3%"><p><b>&minus;F</b></p></td><td width="4%"></td><td width="82%"><p>Use forward searching patterns (e.g. /pattern/)(default). [Ignored in etags mode]</p></td></table><!-- INDENTATION --><table width="100%" border=0 rules="none" frame="void"       cols="2" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="11%"></td><td width="89%"><p><b>&minus;h</b> <i>list</i></p></td></table><!-- INDENTATION --><table width="100%" border=0 rules="none" frame="void"       cols="2" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="18%"></td><td width="82%"><p>Specifies a list of file extensions, separated byperiods, which are to be interpreted as include (or header)files. To indicate files having no extension, use a periodnot followed by a non-period character (e.g. &quot;.&quot;,&quot;..x&quot;, &quot;.x.&quot;). This option only affectshow the scoping of a particular kinds of tags is interpreted(i.e. whether or not they are considered as globally visibleor visible only within the file in which they are defined);it does not map the extension to any particular language.Any tag which is located in a non-include file and cannot beseen (e.g. linked to) from another file is considered tohave file-limited (e.g. static) scope. No kind of tagappearing in an include file will be considered to havefile-limited scope. If the first character in the list is aplus sign, then the extensions in the list will be appendedto the current list; otherwise, the list will replace thecurrent list. See, also, the<b>&minus;&minus;file&minus;scope</b> option. The defaultlist is &quot;.h.H.hh.hpp.hxx.h++.inc.def&quot;. To restorethe default list, specify <b>&minus;h</b> <i>default</i>.Note that if an extension supplied to this option is notalready mapped to a particular language (see <b>SOURCEFILES</b>, above), you will also need to use either the<b>&minus;&minus;langmap</b> or<b>&minus;&minus;language&minus;force</b> option.</p></td></table><!-- INDENTATION --><table width="100%" border=0 rules="none" frame="void"       cols="2" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="11%"></td><td width="89%"><p><b>&minus;I</b> <i>identifier&minus;list</i></p></td></table><!-- INDENTATION --><table width="100%" border=0 rules="none" frame="void"       cols="2" cellspacing="0" cellpadding="0"><tr valign="top" align="left"><td width="18%"></td><td width="82%"><p>Specifies a list of identifiers which are to be speciallyhandled while parsing C and C++ source files. This option isspecifically provided to handle special cases arisingthrough the use of preprocessor macros. When the identifierslisted are simple identifiers, these identifiers will beignored during parsing of the source files. If an identifieris suffixed with a &rsquo;+&rsquo; character, <b>ctags</b>will also ignore any parenthesis-enclosed argument listwhich may immediately follow the identifier in the sourcefiles. If two identifiers are separated with the&rsquo;=&rsquo; character, the first identifiers is replacedby the second identifiers for parsing purposes. The list ofidentifiers may be supplied directly on the command line orread in from a separate file. If the first character of<i>identifier&minus;list</i> is &rsquo;@&rsquo;,&rsquo;.&rsquo; or a pathname separator (&rsquo;/&rsquo; or&rsquo;\&rsquo;), or the first two characters specify adrive letter (e.g. &quot;C:&quot;), the parameter<i>identifier&minus;list</i> will be interpreted as afilename from which to read a list of identifiers, one perinput line. Otherwise, <i>identifier&minus;list</i> is alist of identifiers (or identifier pairs) to be speciallyhandled, each delimited by a either a comma or by whitespace (in which case the list should be quoted to keep theentire list as one command line argument). Multiple<b>&minus;I</b> options may be supplied. To clear the listof ignore identifiers, supply a single dash(&quot;&minus;&quot;) for <i>identifier&minus;list</i>.</p>

⌨️ 快捷键说明

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