Comment by Pawamoy

7 years ago

You could prevent the detection by wrapping contents in a block, so Bash reads it entirely before evaluating it: `safe_curl() { printf "{\n"; curl "$@"; printf " \n}"; }`

Quite a sensible precaution anyway, as network interruption may otherwise leave you with a partially executed script.