]> git.ipfire.org Git - thirdparty/curl.git/commit
curl: add --follow bagder/request-mode 16543/head
authorDaniel Stenberg <daniel@haxx.se>
Fri, 25 Apr 2025 11:09:00 +0000 (13:09 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Thu, 31 Jul 2025 07:21:30 +0000 (09:21 +0200)
commit39543b7fdca66b3191a490b299b70b3bc819e79d
treeeaf274654e28e73ad1bdc2b80749b8dcb1327701
parent4d025fd9120603dfbb3a9bd40747d954de9e9147
curl: add --follow

Makes curl follow redirects an act on the response code and change a
custom method accordingly, contrary to --location.

Potential future command line to send QUERY and following a redirect
according to the status code:

    curl -d "request-body" -X QUERY --follow https://example.com

add test 794,796,797

Assisted-by: Daniel Böhmer <post@daniel-boehmer.de>
Closes #16543
16 files changed:
docs/cmdline-opts/Makefile.inc
docs/cmdline-opts/follow.md [new file with mode: 0644]
docs/cmdline-opts/location-trusted.md
docs/cmdline-opts/location.md
docs/options-in-versions
src/config2setopts.c
src/tool_cfgable.h
src/tool_getparam.c
src/tool_getparam.h
src/tool_listhelp.c
src/tool_setopt.c
src/tool_setopt.h
tests/data/Makefile.am
tests/data/test794 [new file with mode: 0644]
tests/data/test796 [new file with mode: 0644]
tests/data/test797 [new file with mode: 0644]