Validate a one-character Y or N choice.

SolidGroundUX DocumentationSolidGroundUX
NL

fn: sgnd_validate_yesno

Purpose

Validate a one-character Y or N choice.

Arguments

  • $1 — Candidate value.

Returns

  • 0 for Y/y/N/n; 1 otherwise.

Usage

  sgnd_validate_yesno y