blob: 9fed64bf4fe8d26fa102703c4ec82219b73e75af [file] [log] [blame]
lh9ed821d2023-04-07 01:36:19 -07001Long: remote-name
2Short: O
3Help: Write output to a file named as the remote file
4---
5Write output to a local file named like the remote file we get. (Only the file
6part of the remote file is used, the path is cut off.)
7
8The file will be saved in the current working directory. If you want the file
9saved in a different directory, make sure you change the current working
10directory before invoking curl with this option.
11
12The remote file name to use for saving is extracted from the given URL,
13nothing else, and if it already exists it will be overwritten. If you want the
14server to be able to choose the file name refer to --remote-header-name which
15can be used in addition to this option. If the server chooses a file name and
16that name already exists it will not be overwritten.
17
18There is no URL decoding done on the file name. If it has %20 or other URL
19encoded parts of the name, they will end up as-is as file name.
20
21You may use this option as many times as the number of URLs you have.