Using the Functions for Generating Output
Reporting state on the system requires generating output. Scripts have several
built-in functions made available to them to generate output:
Table 10 Built-in Functions for Generating Output
|
|
dump
|
Dumps the specified argument to the terminal, without expanding
embedded newlines. Objects will be displayed in a JSON-like format.
Useful for debugging.
|
print
|
Prints the specified object as a string, followed by a newline. If
the object does not have a toString method, it
will be printed opaquely.
|
printf
|
Like C's printf(3C), prints the specified arguments according to
the specified formatting string.
|
|