Интерактивная система просмотра системных руководств (man-ов)
cscope (1)
>> cscope (1) ( Solaris man: Команды и прикладные программы пользовательского уровня )
cscope (1) ( Linux man: Команды и прикладные программы пользовательского уровня )
NAME
cscope - interactively examine a C program
SYNOPSIS
ccssccooppee [[options]] files......
DESCRIPTION
ccssccooppee is an interactive screen-oriented tool that allows
the user to browse through C source files for specified ele-
ments of code.
By default, ccssccooppee examines the C (..cc and ..hh), lleexx (..ll), and
yyaacccc (..yy) source files in the current directory. ccssccooppee may
also be invoked for source files named on the command line.
In either case, ccssccooppee searches the standard directories for
##iinncclluuddee files that it does not find in the current direc-
tory. ccssccooppee uses a symbol cross-reference, ccssccooppee..oouutt by
default, to locate functions, function calls, macros, vari-
ables, and preprocessor symbols in the files.
ccssccooppee builds the symbol cross-reference the first time it
is used on the source files for the program being browsed.
On a subsequent invocation, ccssccooppee rebuilds the cross-
reference only if a source file has changed or the list of
source files is different. When the cross-reference is
rebuilt, the data for the unchanged files are copied from
the old cross-reference, which makes rebuilding faster than
the initial build.
The following options can appear in any combination:
--bb Build the cross-reference only.
--CC Ignore letter case when searching.
--cc Use only ASCII characters in the cross-
reference file, that is, do not compress the
data.
--dd Do not update the cross-reference.
--ee Suppress the ^^ee command prompt between files.
--ff reffile Use reffile as the cross-reference file name
instead of the default ccssccooppee..oouutt.
--II incdir Look in incdir (before looking in the stan-
dard place for header files, normally
//uussrr//iinncclluuddee) for any ##iinncclluuddee files whose
names do not begin with // and that are not
specified on the command line or in namefile
below. (The ##iinncclluuddee files may be specified
with either double quotes or angle brackets.)
The incdir directory is searched in addition
to the current directory (which is searched
first) and the standard list (which is
searched last). If more than one occurrence
of --II appears, the directories are searched
in the order they appear on the command line.
--ii namefile Browse through all source files whose names
are listed in namefile (file names separated
by spaces, tabs, or new-lines) instead of the
default (ccssccooppee..ffiilleess). If this option is
specified, ccssccooppee ignores any files appearing
on the command line.
--LL Do a single search with line-oriented output
when used with the --numpattern option.
--ll Line-oriented interface (see ``Line-Oriented
Interface'' below).
--numpattern Go to input field num (counting from 0) and
find pattern.
--PP path Prepend path to relative file names in a
pre-built cross-reference file so you do not
have to change to the directory where the
cross-reference file was built. This option
is only valid with the --dd option.
--pp n Display the last n file path components
instead of the default (1). Use 0 to not
display the file name at all.
--ss dir Look in dir for additional source files.
This option is ignored if source files are
given on the command line.
--TT Use only the first eight characters to match
against C symbols. A regular expression con-
taining special characters other than a
period (.) will not match any symbol if its
minimum length is greater than eight charac-
ters.
--UU Do not check file time stamps (assume that no
files have changed).
--uu Unconditionally build the cross-reference
file (assume that all files have changed).
--VV Print on the first line of screen the version
number of ccssccooppee.
The --II, --pp, and --TT options can also be in the ccssccooppee..ffiilleess
file.
Requesting the Initial Search
After the cross-reference is ready, ccssccooppee will display this
menu:
Find this C symbol:
Find this global definition:
Find functions called by this function:
Find functions calling this function:
Find this text string:
Change this text string:
Find this egrep pattern:
Find this file:
Find files #including this file:
Press the TTAABB key repeatedly to move to the desired input
field, type the text to search for, and then press the
RREETTUURRNN key.
Issuing Subsequent Requests
If the search is successful, any of these single-character
commands can be used:
11--99 Edit the file referenced by the given line
number.
SSPPAACCEE Display next set of matching lines.
++ Display next set of matching lines.
-- Display previous set of matching lines.
^^ee Edit displayed files in order.
>> Append the displayed list of lines to a file.
|| Pipe all lines to a shell command.
At any time these single-character commands can also be
used:
TTAABB Move to next input field.
RREETTUURRNN Move to next input field.
^^nn Move to next input field.
^^pp Move to previous input field.
^^yy Search with the last text typed.
^^