docs/cmdline: change to .md for cmdline docs
- switch all invidual files documenting command line options into .md,
as the documentation is now markdown-looking.
- made the parser treat 4-space indents as quotes
- switch to building the curl.1 manpage using the "mainpage.idx" file,
which lists the files to include to generate it, instead of using the
previous page-footer/headers. Also, those files are now also .md
ones, using the same format. I gave them underscore prefixes to make
them sort separately:
_NAME.md, _SYNOPSIS.md, _DESCRIPTION.md, _URL.md, _GLOBBING.md,
_VARIABLES.md, _OUTPUT.md, _PROTOCOLS.md, _PROGRESS.md, _VERSION.md,
_OPTIONS.md, _FILES.md, _ENVIRONMENT.md, _PROXYPREFIX.md,
_EXITCODES.md, _BUGS.md, _AUTHORS.md, _WWW.md, _SEEALSO.md
- updated test cases accordingly
Closes #12751
2024-01-21 06:18:43 +08:00
|
|
|
---
|
2023-01-02 20:51:48 +08:00
|
|
|
c: Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
|
2022-06-14 06:12:03 +08:00
|
|
|
SPDX-License-Identifier: curl
|
2016-11-16 06:44:58 +08:00
|
|
|
Long: remote-header-name
|
|
|
|
Short: J
|
|
|
|
Protocols: HTTP
|
|
|
|
Help: Use the header-provided filename
|
2020-07-13 20:15:04 +08:00
|
|
|
Category: output
|
2021-09-28 17:50:07 +08:00
|
|
|
Added: 7.20.0
|
2022-10-18 16:39:43 +08:00
|
|
|
Multi: boolean
|
docs/cmdline: change to .md for cmdline docs
- switch all invidual files documenting command line options into .md,
as the documentation is now markdown-looking.
- made the parser treat 4-space indents as quotes
- switch to building the curl.1 manpage using the "mainpage.idx" file,
which lists the files to include to generate it, instead of using the
previous page-footer/headers. Also, those files are now also .md
ones, using the same format. I gave them underscore prefixes to make
them sort separately:
_NAME.md, _SYNOPSIS.md, _DESCRIPTION.md, _URL.md, _GLOBBING.md,
_VARIABLES.md, _OUTPUT.md, _PROTOCOLS.md, _PROGRESS.md, _VERSION.md,
_OPTIONS.md, _FILES.md, _ENVIRONMENT.md, _PROXYPREFIX.md,
_EXITCODES.md, _BUGS.md, _AUTHORS.md, _WWW.md, _SEEALSO.md
- updated test cases accordingly
Closes #12751
2024-01-21 06:18:43 +08:00
|
|
|
See-also:
|
|
|
|
- remote-name
|
|
|
|
Example:
|
|
|
|
- -OJ https://example.com/file
|
2016-11-16 06:44:58 +08:00
|
|
|
---
|
docs/cmdline: change to .md for cmdline docs
- switch all invidual files documenting command line options into .md,
as the documentation is now markdown-looking.
- made the parser treat 4-space indents as quotes
- switch to building the curl.1 manpage using the "mainpage.idx" file,
which lists the files to include to generate it, instead of using the
previous page-footer/headers. Also, those files are now also .md
ones, using the same format. I gave them underscore prefixes to make
them sort separately:
_NAME.md, _SYNOPSIS.md, _DESCRIPTION.md, _URL.md, _GLOBBING.md,
_VARIABLES.md, _OUTPUT.md, _PROTOCOLS.md, _PROGRESS.md, _VERSION.md,
_OPTIONS.md, _FILES.md, _ENVIRONMENT.md, _PROXYPREFIX.md,
_EXITCODES.md, _BUGS.md, _AUTHORS.md, _WWW.md, _SEEALSO.md
- updated test cases accordingly
Closes #12751
2024-01-21 06:18:43 +08:00
|
|
|
|
|
|
|
# `--remote-header-name`
|
|
|
|
|
2016-11-16 06:44:58 +08:00
|
|
|
This option tells the --remote-name option to use the server-specified
|
2022-01-09 18:34:37 +08:00
|
|
|
Content-Disposition filename instead of extracting a filename from the URL. If
|
2024-02-27 17:35:28 +08:00
|
|
|
the server-provided filename contains a path, that is stripped off before the
|
|
|
|
filename is used.
|
2022-01-09 18:34:37 +08:00
|
|
|
|
|
|
|
The file is saved in the current directory, or in the directory specified with
|
|
|
|
--output-dir.
|
2016-11-16 06:44:58 +08:00
|
|
|
|
2024-02-27 17:35:28 +08:00
|
|
|
If the server specifies a filename and a file with that name already exists in
|
|
|
|
the destination directory, it is not overwritten and an error occurs - unless
|
|
|
|
you allow it by using the --clobber option. If the server does not specify a
|
|
|
|
filename then this option has no effect.
|
2016-11-16 06:44:58 +08:00
|
|
|
|
2024-02-27 17:35:28 +08:00
|
|
|
There is no attempt to decode %-sequences (yet) in the provided filename, so
|
|
|
|
this option may provide you with rather unexpected filenames.
|
2016-11-16 06:44:58 +08:00
|
|
|
|
2024-02-07 01:07:07 +08:00
|
|
|
This feature uses the name from the `filename` field, it does not yet support
|
|
|
|
the `filename*` field (filenames with explicit character sets).
|
2023-02-18 17:18:57 +08:00
|
|
|
|
2021-03-22 23:50:57 +08:00
|
|
|
**WARNING**: Exercise judicious use of this option, especially on Windows. A
|
2021-11-26 15:46:59 +08:00
|
|
|
rogue server could send you the name of a DLL or other file that could be
|
|
|
|
loaded automatically by Windows or some third party software.
|