Microsoft
Software
Hardware
Network
Question : Bash: curl and redirected url
Hi experts,
I know that
status=$(curl -s --head "$URL" | awk '/HTTP/ {print $2})
gives http code such as "200" or "404" Assume that the code is "310" ("moved permanently"), then how to use "curl" to retrieve the new url?
I googled but I got no answers.
Thanks for any replies.
Answer : Bash: curl and redirected url
NewURL=$(curl -s --head "$URL" | awk '/Location:/ {print $2}')
Random Solutions
SQL Server ODBC Link to read/write access table
SCRIPT for generate BCP flat file ...from MYSQL file <MIGRATION>
Remove "set as desktop background" in windows picture and fax viewer
how configure 2 mailbox to one user
Set permissions to allow .exe file to execute within IIS instead of download
Make entire movie clip have a pulsate/blink effect when stopped?
is OMA still using v1.1 ?
Illustrator - saving as PDF produces wishy washy colours
Folder name with space cannot cd
Windows update failing to install