Bash curl returns 0 whenever the copy has finished or not -


i'm calling curl on bash copy file mounted sd card option resume copy later if device gets unmounted. receive same status exit code 0 when interrupt copy unmounting volume , when file gets copied. suggestions how catch case file has not been copied?

i'm copying 1 file @ time.

this command:

curl -c - -o file:///mnt/sdcard/dcim/100/0044.mp4 

i came solution not clear want, still working. i'm executing command 2 times 1 after another, when first command returns 0 upon unmount, second tries copy file , return error code 37 because of unreachable source. if second command returns 0 consider file copied.


Comments

Popular posts from this blog

html - How to style widget with post count different than without post count -

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

javascript - storing input from prompt in array and displaying the array -