curl / Mailing Lists / curl-users / Single Mail

curl-users

Easily find the exit code of curl

From: Jon Harris <jharris_at_symetrix.co>
Date: Sat, 27 Apr 2019 18:13:04 +0000

I am looking for an easy way to find the exit code of a curl process that was running in the background. A logical place would be one of the variables available through --write-out but that doesn't appear to exist. Could this be added?
Related, how about an option for --write-out to go to a file instead of stdout or stderr. That makes it possible to isolate this info from other possibly useful output.

Any suggestions for a work-around? I thought about parsing through the various outputs I can get from curl, but that seems difficult. I also want to get at other information such as the normal stdout, stderr and sometimes the --trace-ascii.

-----------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-users
Etiquette: https://curl.haxx.se/mail/etiquette.html
Received on 2019-04-27