PortValhalla/scripts/Common/Scripts/is-truthy.sh

11 lines
194 B
Bash
Raw Normal View History

function isTruthy() {
local value;
value="$1";
[ ! -z "$value" ] &&
[ "$value" != "0" ] &&
[ "$value" != "false" ] &&
[ "$value" != "n" ] &&
[ "$value" != "no" ];
}