#!/bin/bash
# gsu -- the global subcommand utility
-# (C) 2006-2010 Andre Noll
+# (C) 2006-2011 Andre Noll
_gsu_init_errors()
{
return
esac
- eval ${gsu_config_var_prefix}_$name='"'${val:=$default_value}'"'
+ eval ${gsu_config_var_prefix}_$name='"'\${val:=$default_value}'"'
# Check option type. ATM, only num and string are supported
# Other types may be added without breaking compatibility
case "$option_type" in
ret=-$E_GSU_GETOPTS
result="invalid optstring $1"
- if [[ -z "$1" || "$1" =~ "::" ]]; then
+ if [[ -z "$1" ]] || grep -q '::' <<< "$1" ; then
gsu_err_msg
exit 1
fi