1TYPE(1P) POSIX Programmer's Manual TYPE(1P)
2
3
4
6 This manual page is part of the POSIX Programmer's Manual. The Linux
7 implementation of this interface may differ (consult the corresponding
8 Linux manual page for details of Linux behavior), or the interface may
9 not be implemented on Linux.
10
11
13 type — write a description of command type
14
16 type name...
17
19 The type utility shall indicate how each argument would be interpreted
20 if used as a command name.
21
23 None.
24
26 The following operand shall be supported:
27
28 name A name to be interpreted.
29
31 Not used.
32
34 None.
35
37 The following environment variables shall affect the execution of type:
38
39 LANG Provide a default value for the internationalization vari‐
40 ables that are unset or null. (See the Base Definitions vol‐
41 ume of POSIX.1‐2008, Section 8.2, Internationalization Vari‐
42 ables for the precedence of internationalization variables
43 used to determine the values of locale categories.)
44
45 LC_ALL If set to a non-empty string value, override the values of
46 all the other internationalization variables.
47
48 LC_CTYPE Determine the locale for the interpretation of sequences of
49 bytes of text data as characters (for example, single-byte as
50 opposed to multi-byte characters in arguments).
51
52 LC_MESSAGES
53 Determine the locale that should be used to affect the format
54 and contents of diagnostic messages written to standard
55 error.
56
57 NLSPATH Determine the location of message catalogs for the processing
58 of LC_MESSAGES.
59
60 PATH Determine the location of name, as described in the Base Def‐
61 initions volume of POSIX.1‐2008, Chapter 8, Environment Vari‐
62 ables.
63
65 Default.
66
68 The standard output of type contains information about each operand in
69 an unspecified format. The information provided typically identifies
70 the operand as a shell built-in, function, alias, or keyword, and where
71 applicable, may display the operand's pathname.
72
74 The standard error shall be used only for diagnostic messages.
75
77 None.
78
80 None.
81
83 The following exit values shall be returned:
84
85 0 Successful completion.
86
87 >0 An error occurred.
88
90 Default.
91
92 The following sections are informative.
93
95 Since type must be aware of the contents of the current shell execution
96 environment (such as the lists of commands, functions, and built-ins
97 processed by hash), it is always provided as a shell regular built-in.
98 If it is called in a separate utility execution environment, such as
99 one of the following:
100
101 nohup type writer
102 find . −type f | xargs type
103
104 it might not produce accurate results.
105
107 None.
108
110 None.
111
113 None.
114
116 command, hash
117
118 The Base Definitions volume of POSIX.1‐2008, Chapter 8, Environment
119 Variables
120
122 Portions of this text are reprinted and reproduced in electronic form
123 from IEEE Std 1003.1, 2013 Edition, Standard for Information Technology
124 -- Portable Operating System Interface (POSIX), The Open Group Base
125 Specifications Issue 7, Copyright (C) 2013 by the Institute of Electri‐
126 cal and Electronics Engineers, Inc and The Open Group. (This is
127 POSIX.1-2008 with the 2013 Technical Corrigendum 1 applied.) In the
128 event of any discrepancy between this version and the original IEEE and
129 The Open Group Standard, the original IEEE and The Open Group Standard
130 is the referee document. The original Standard can be obtained online
131 at http://www.unix.org/online.html .
132
133 Any typographical or formatting errors that appear in this page are
134 most likely to have been introduced during the conversion of the source
135 files to man page format. To report such errors, see https://www.ker‐
136 nel.org/doc/man-pages/reporting_bugs.html .
137
138
139
140IEEE/The Open Group 2013 TYPE(1P)