I'm using curl -F file=@- http://etc/upload
to upload some data I'm piping into cURL, and that's working fine, but I'd like to be able to specify the file name that's reported to the server.
Is that possible? How?
For protocols other than HTTP, and to use PUT
for HTTP rather than form submission, use -T -
with filename in URL:
echo bla-bla-bla | curl -T - ftp://user:[email protected]/foo.txt
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With