Issue
I want to create a batch file that would download file from url https://someurl.com/file which redirects me to https://someurl.com/file/download/smth.txt. How can I do this without using anything other than batch?
Solution
You can use -L, --location
parametr to follow rediects.
Example :
curl "https://someurl.com/file" -L -o smth.txt
Also you can use --max-redirs <num>
parameter to limit the number of redirects.
More inforamtion about these parameters and other you can find on curl.se, -L parameter, --max-redirs
Answered By - kamack38