diff --git a/lib/general.sh b/lib/general.sh index f2c68fe0..da756bc3 100644 --- a/lib/general.sh +++ b/lib/general.sh @@ -47,6 +47,12 @@ shellspec_constants() { " # shellcheck disable=SC2059 eval "$(printf "$SHELLSPEC_EVAL")" + + # Workaround: Variable CR is empty on MSYS + if eval "[ \${#${1}CR} -eq 0 ] &&:"; then + set -- "$1" "$(printf '\015')" + eval "${1}CR=\$2" + fi } shellspec_constants SHELLSPEC_