SHTK_CONFIG_HAS(3)
π NAME π
okay so bestie, this is SHTK_CONFIG_HAS(3), from the Library Functions Manual β manual name folded in right here like a little name tag, no cap. It's the page for shtk_config_has, and it checks if a configuration variable is set. that's the assignment. π
π§ LIBRARY π§
you get this function by importing the config library. the line is literally:
shtk_import config? Wait, exact: shtk_import config β yes, that one. π«Ά
β¨ SYNOPSIS β¨
shtk_config_has var_name
just pass var_name and go. short, sweet, iconic. π
π¦ DESCRIPTION π¦
so the shtk_config_has function checks whether the configuration variable var_name has been previously set β either by a call to shtk_config_set(3) inside the script, or by the user in the configuration file. that's the vibe check it performs. πΈ
and the part that's genuinely highkey smart: shtk_config_has properly distinguishes between a variable that has never been defined and a variable that has been defined to the empty value. not me being obsessed with this level of emotional intelligence π. it does not blur those two cases together. π
π RETURN VALUES π
0(true) β whenvar_namehas been defined. slay. β¨1(false) β otherwise. π
π SEE ALSO π
go read those if you're in your lore era. iykyk. π₯
π HISTORY π
shtk_config_has first appeared in shtk 1.0. iconic from day one, fr fr. π¦
mwah π β this little page came from Debian, dated November 6, 2014, and it's filed under SHTK_CONFIG_HAS(3). that's the source/version-and-date sign-off, periodt. π
π¦ 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