1DOT(P) POSIX Programmer's Manual DOT(P)
2
3
4
6 dot - execute commands in the current environment
7
9 . file
10
12 The shell shall execute commands from the file in the current environ‐
13 ment.
14
15 If file does not contain a slash, the shell shall use the search path
16 specified by PATH to find the directory containing file. Unlike normal
17 command search, however, the file searched for by the dot utility need
18 not be executable. If no readable file is found, a non-interactive
19 shell shall abort; an interactive shell shall write a diagnostic mes‐
20 sage to standard error, but this condition shall not be considered a
21 syntax error.
22
24 None.
25
27 See the DESCRIPTION.
28
30 Not used.
31
33 See the DESCRIPTION.
34
36 See the DESCRIPTION.
37
39 Default.
40
42 Not used.
43
45 The standard error shall be used only for diagnostic messages.
46
48 None.
49
51 None.
52
54 Returns the value of the last command executed, or a zero exit status
55 if no command is executed.
56
58 Default.
59
60 The following sections are informative.
61
63 None.
64
66 cat foobar
67 foo=hello bar=world. foobar
68 echo $foo $bar
69 hello world
70
72 Some older implementations searched the current directory for the file,
73 even if the value of PATH disallowed it. This behavior was omitted
74 from this volume of IEEE Std 1003.1-2001 due to concerns about intro‐
75 ducing the susceptibility to trojan horses that the user might be try‐
76 ing to avoid by leaving dot out of PATH .
77
78 The KornShell version of dot takes optional arguments that are set to
79 the positional parameters. This is a valid extension that allows a dot
80 script to behave identically to a function.
81
83 None.
84
86 Special Built-In Utilities
87
89 Portions of this text are reprinted and reproduced in electronic form
90 from IEEE Std 1003.1, 2003 Edition, Standard for Information Technology
91 -- Portable Operating System Interface (POSIX), The Open Group Base
92 Specifications Issue 6, Copyright (C) 2001-2003 by the Institute of
93 Electrical and Electronics Engineers, Inc and The Open Group. In the
94 event of any discrepancy between this version and the original IEEE and
95 The Open Group Standard, the original IEEE and The Open Group Standard
96 is the referee document. The original Standard can be obtained online
97 at http://www.opengroup.org/unix/online.html .
98
99
100
101IEEE/The Open Group 2003 DOT(P)