卷曲并运行python脚本 [英] curl and run python script
本文介绍了卷曲并运行python脚本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
更简单的方法是什么
wget https://bootstrap.pypa.io/get-pip.py
sudo python get-pip.py
?
我尝试过:
?
I tried this:
sudo <(python <(curl https://bootstrap.pypa.io/get-pip.py))
,但返回错误: "IOError:[Errno 32]管道损坏"
but it returns the error: 'IOError: [Errno 32] Broken pipe'
这有效:python <(curl https://bootstrap.pypa.io/get-pip.py)
但需要sudo
推荐答案
curl https://bootstrap.pypa.io/get-pip.py | sudo python -
curl
会将给定的URL输出到stdout
curl
will output given URL to stdout
python -
表示该来源将来自标准输入.
python -
indicate, that source will be taken from stdin.
这篇关于卷曲并运行python脚本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文