SHTK_CLI_ERROR(3)
π NAME π
okay bestie, welcome to the SHTK_CLI_ERROR(3) page β itβs serving Library Functions Manual energy, and itβs all about shtk_cli_error, the function that prints a runtime error message and exits. Very βwe are ending this script with receiptsβ of it. π
π LIBRARY π
You get this one by importing the CLI library: shtk_import cli.
β¨ SYNOPSIS β¨
shtk_cli_error message1 [.. messageN]
π¦ DESCRIPTION π¦
The function shtk_cli_error prints the given runtime error message to stderr and then terminates execution of the script with a return value of 1. It is literally the bail-out button. π
The message can be handed over as one or more arguments β thatβs the message1 to messageN situation β and all arguments are concatenated together into a single line. So yes bestie, you can pass multiple pieces and they get smushed into one line. π«Ά
The printed message has this exact form, where progname is determined by shtk_cli_progname(3):
progname: E: message1 .. messageN
Use shtk_cli_error when you need to bail out on erroneous conditions that are not directly caused by an invalid invocation of the script. For errors caused directly by the user β like specifying an incorrect flag to the program β report them with shtk_cli_usage_error(3). Thatβs the vibe check: wrong user flag goes to usage error, other runtime oops goes here. π
π SEE ALSO π
π HISTORY π
shtk_cli_error first appeared in shtk 1.0. Iconic. β
okay thatβs the whole page, bestie β the footer says Debian and November 5, 2014, so thatβs the source/version + date tea. mwah π
π¦ where this page comes from
- nixos 26.05: shtk 1.7
- nixpkgs unstable: shtk 1.7
- Copyright 2014 Google Inc
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms