gid [-ffile] [-edoxamse] patterns...
eid [-ffile] [-doxamse] patterns...
aid [-ffile] [-doxamsv] patterns...
idname ../hdir/hfile.h ../cdir/{cfile1,cfile2}.c
Notice that multiple files with the same directory prefix and suffix are concatenated in the globbing-set-notation of csh(1) (see the -v flag to alter this behaviour). Also notice that all of the id database query commands adjust the list of pathnames to be relative to your current working directory, provided that mkid(1) was used to build the database, and your working directory is located within the sub-tree covered by the id database.
If multiple names match on pattern, then there will be one line of output per name. The mnemonic significance of the name is l(ookup) id.
Gid does a lookup and then searches for the names it matches in the files where they occur. The mnemonic for this name is g(rep)id.
Eid does a lookup, and then invokes an editor on all files with the matched name as an initial search string. Of course, this name stands for e(dit) id.
Eid uses four environment variables to control its invocation of the editor. Naturally, EDITOR is used to locate the editing program. EIDARG is a printf(3S) string used to specify the form of the initial-search-string argument. If the editor does not support such an argument, this variable may be left unset. EIDLDEL and EIDRDEL specify the form of the left and right word-delimiters respectively. The best way to explain the use of these last three variables is with an example. Here are the proper settings for vi(1):
EIDARG='+/%s/' # initial search argument template EIDLDEL='\<' # left word-delimiter EIDRDEL='\>' # right word-delimiter
Patterns may be simple alpha-numeric strings, or regular expressions in the style of regcmp(3). If the string contains no regular-expression meta-characters, it is searched for as a word. If the string contains meta-characters, or if the -e argument is supplied, it is searched for as regular-expression.
Aid produces output in the style of lid but its pattern arguments are searched for as substrings within the identifiers in the database. No regular-expression search is performed, even if the pattern contains meta-characters. The search is conducted in an alphabetic case insensitive manner. The mnemonic for this name is a(propos) id.
The following options are recognized:
The remaining options are for use in conjunction with numeric patterns:
Searches for numbers are conducted numerically rather than lexically, so that all representations for a given number are potentially available from a single search.