omg*_*omg 7 linux url file file-uri
喜欢/usr/local?
我试过file:///usr/local但失败了
[root@www2 robot]# cd file:///usr/local
-bash: cd: file:///usr/local: No such file or directory
Run Code Online (Sandbox Code Playgroud)
如果您需要能够从shell访问通用URL,请尝试使用curl替换您的cat:
curl file:///path/to/file.txt
curl http://www.domain.com/file.txt
Run Code Online (Sandbox Code Playgroud)
但正如其他海报所指出的那样,shell本身并不理解URL.
Zif*_*fre -1
该file:协议仅存在于网络浏览器中。在 Firefox 中尝试一下,应该可以工作。要在 shell 中执行此操作,只需使用
cd /usr/local/
不要使用file:. 这和你不能的原因是一样的
猫 http://www.google.com
这会很棒(但你必须使用类似wget或 的东西curl)。
| 归档时间: |
|
| 查看次数: |
36807 次 |
| 最近记录: |