diff --git a/dev/ofunctions.sh b/dev/ofunctions.sh index d042ead..cdc190c 100644 --- a/dev/ofunctions.sh +++ b/dev/ofunctions.sh @@ -8,7 +8,7 @@ #### OFUNCTIONS FULL SUBSET #### #### OFUNCTIONS MINI SUBSET #### _OFUNCTIONS_VERSION=2.3.0-dev -_OFUNCTIONS_BUILD=2018070202 +_OFUNCTIONS_BUILD=2018070301 #### _OFUNCTIONS_BOOTSTRAP SUBSET #### _OFUNCTIONS_BOOTSTRAP=true #### _OFUNCTIONS_BOOTSTRAP SUBSET END #### @@ -1257,6 +1257,13 @@ function EscapeSpaces { echo "${string// /\\ }" } +# Usage var=$(EscapeDoubleQuotes "$var") or var="$(EscapeDoubleQuotes "$var")" +function EscapeDoubleQuotes { + local value="${1}" + + echo "${value//\"/\\\"}" +} + function IsNumericExpand { eval "local value=\"${1}\"" # Needed eval so variable variables can be processed