Simple.. use the -O option which tells that the downloaded file should be named as that of the original file that are we are trying to download.
For e.g.,
curl -O http://mydomain.com/example.zip
This will download the file example.zip into the same directory from where you are running this command and will name the downloaded file as example.zip.
There are a lot of options which can be used with curl. For a list of them see curl --help.
An excellent link which I found that details various curl day to day examples is http://www.thegeekstuff.com/2012/04/curl-examples/.
No comments:
Post a Comment