fish/doc_src/type.txt
David Adam (zanchey) 1287b9d823 Help cleanup
Large list of changes, including formatting and typos for most commands.

More substantive changes have been made to alias, bind, block, break,
builtin, case, cd, commandline, count, else, emit, fish_config, funced,
function, functions, history, math, mimedb, nextd, not, popd, prevd,
pushd, pwd, random, read, set, set_color, switch, test, trap, type,
ulimit, umask, and while.
2013-05-13 01:48:20 -07:00

25 lines
1.2 KiB
Plaintext

\section type type - indicate how a command would be interpreted
\subsection type-synopsis Synopsis
<tt>type [OPTIONS] NAME [NAME ...]</tt>
\subsection type-description Description
With no options, \c type indicates how each \c NAME would be interpreted if used as a command name.
The following options are available:
- \c -h or \c --help prints help and then exits.
- \c -a or \c --all prints all of possible definitions of the specified names.
- \c -f or \c --no-functions suppresses function and builtin lookup.
- \c -t or \c --type prints <tt>keyword</tt>, <tt>function</tt>, <tt>builtin</tt>, or <tt>file</tt> if \c NAME is a shell reserved word, function, builtin, or disk file, respectively.
- \c -p or \c --path returns the name of the disk file that would be executed, or nothing if 'type -t name' would not return 'file'.
- \c -P or \c --force-path returns the name of the disk file that would be executed, or nothing no file with the specified name could be found in the <tt>$PATH</tt>.
\c type sets the exit status to 0 if the specified command was found,
and 1 if it could not be found.
\subsection type-example Example
<tt>type fg</tt> outputs the string 'fg is a shell builtin'.