sh 按照命令行重定向

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了sh 按照命令行重定向相关的知识,希望对你有一定的参考价值。

curl -s -I $url | grep \^Location: | cut -d ':' -f 2-

# I had a longer version that continued following redirects up to a limit, but
# can't find it atm

# if you'd like to do the above anonymously, you can use https://hurl.it and
# change the HTTP method from GET to HEAD and paste in your URL (assuming HEAD 
# is supported by the webserver).  In the response you'll see the 
# Location: HTTP header w/the redirected URL (assuming nominal situation).

以上是关于sh 按照命令行重定向的主要内容,如果未能解决你的问题,请参考以下文章

从命令行重命名多个文件[重复]

从命令行重命名 Github repo

在 ssh 之后从命令行重命名控制台会话

如何在单个可执行文件中将数据重定向到标准输入?

sh 通过命令行检查重定向

linux中如何用rename命令重命名一个文件