next up previous contents index
Next: User Interface Setup Commands Up: String Comparison and Global Previous: The strciprefix Command   Contents   Index

The retval Command

The retval command will set the global return value to the numeric value given.

retval value
This can be used to pass a value back from a script, or to pass a value to a script. The global return value is a global value available in any script, and is accessed with the $? construct. The global return value is set only by this function and the string comparison functions. It is initialized to zero on program startup, and retains the latest value indefinitely.

Stephen R. Whiteley 2018-10-10