1COLON(P) POSIX Programmer's Manual COLON(P)
2
3
4
6 colon - null utility
7
9 : [argument ...]
10
12 This utility shall only expand command arguments. It is used when a
13 command is needed, as in the then condition of an if command, but noth‐
14 ing is to be done by the command.
15
17 None.
18
20 See the DESCRIPTION.
21
23 Not used.
24
26 None.
27
29 None.
30
32 Default.
33
35 Not used.
36
38 The standard error shall be used only for diagnostic messages.
39
41 None.
42
44 None.
45
47 Zero.
48
50 Default.
51
52 The following sections are informative.
53
55 None.
56
58 : ${X=abc}
59 if false
60 then :
61 else echo $X
62 fi
63 abc
64
65 As with any of the special built-ins, the null utility can also have
66 variable assignments and redirections associated with it, such as:
67
68
69 x=y : > z
70
71 which sets variable x to the value y (so that it persists after the
72 null utility completes) and creates or truncates file z.
73
75 None.
76
78 None.
79
81 Special Built-In Utilities
82
84 Portions of this text are reprinted and reproduced in electronic form
85 from IEEE Std 1003.1, 2003 Edition, Standard for Information Technology
86 -- Portable Operating System Interface (POSIX), The Open Group Base
87 Specifications Issue 6, Copyright (C) 2001-2003 by the Institute of
88 Electrical and Electronics Engineers, Inc and The Open Group. In the
89 event of any discrepancy between this version and the original IEEE and
90 The Open Group Standard, the original IEEE and The Open Group Standard
91 is the referee document. The original Standard can be obtained online
92 at http://www.opengroup.org/unix/online.html .
93
94
95
96IEEE/The Open Group 2003 COLON(P)