Following redirects with curl

Using curl by default will return the response of a request as-is. If the response is a redirect, you can tell curl to follow the redirect with the -L option, e.g.

curl -L http://some.site

To use curl to download a file, use the -O option.

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.