Comment on "So that a truncated partial download doesn't end up executing half a script"parentComments−loeg2yBrowsers typically emit downloads to temporary files until they are complete, then rename them into the final location, to prevent this kind of issue.−kevincox2yTools like wget or curl often do not. And the shell doesn't when doing something like `curl ... >myscript.sh`.−loeg2ySure. Just pointing out that there's a good reason browsers do this.
Comments
Browsers typically emit downloads to temporary files until they are complete, then rename them into the final location, to prevent this kind of issue.
Tools like wget or curl often do not. And the shell doesn't when doing something like `curl ... >myscript.sh`.
Sure. Just pointing out that there's a good reason browsers do this.