19.0.0 released Nov 08, 2023
Exit code

Purpose: Return exit code when running from the command-line.

exit-code <exit code>

exit-code specifies <exit code> (which must be an integer expression) when the program runs from the command-line.

exit-code can be specified anywhere in the code, and does not mean exiting the program. To exit the program, either use exit-request or simply allow request function to reach its end.

When exit-code is not used, the default exit code is 0.
Examples
When the program exits, its exit code will be 12:
exit-code 12
...
exit-request

See also
Program execution
exec-program  
exit-code    
See all
documentation


You are free to copy, redistribute and adapt this web page (even commercially), as long as you give credit and provide a dofollow link back to this page - see full license at CC-BY-4.0. Copyright (c) 2019-2023 Dasoftver LLC. Vely and elephant logo are trademarks of Dasoftver LLC. The software and information on this web site are provided "AS IS" and without any warranties or guarantees of any kind. Icons from table-icons.io copyright Paweł Kuna, licensed under MIT license.