不要再运行“curl sh”。在运行之前使用“curl shed”来验证脚本。
shed_sh的Python项目详细描述
SHED-sh编辑器
不要再运行curl | sh。使用curl | shed验证脚本 在跑步之前。
用法
在运行的任何管道sh命令中,将sh替换为shed。棚将:
- 将管道脚本保存到临时文件中
- 打开$SHED_EDITOR或$EDITOR中的临时文件,以便查看 并修改脚本
- 询问您是否仍要运行脚本,保留任何更改 你做了
安装
这是一个python 3脚本,因此使用pip3安装:
pip3 install shed_sh
注意拼写:shed_sh与shed不同。
在此之后,从终端运行shed或bashed以验证 安装正确。
示例
管道至SH
接受可疑的curl-pipe sh或wget-pipe sh命令
curl -L https://npmjs.org/install.sh | sh wget -qO- https://toolbelt.heroku.com/install-ubuntu.sh | sh
并在运行脚本之前使用SHED查看和编辑脚本:
curl -L https://npmjs.org/install.sh | shed wget -qO- https://toolbelt.heroku.com/install-ubuntu.sh | shed
管道至bash
bashed也保护您的bashshell:使用这个未知脚本
wget -q -O - https://fixubuntu.com/fixubuntu.sh | bash
并在运行之前验证内容:
wget -q -O - https://fixubuntu.com/fixubuntu.sh | bashed
配置
设置首选编辑器:
export SHED_EDITOR=vim
shed还检查$EDITOR,然后返回到nano,vim, vi,和emacs顺序排列。
贡献
错误报告、修复或功能?随意打开问题或拉动 随时请求。你也可以发推特给我 [@mplewis](http://twitter.com/mplewis)或发电子邮件给我。
许可证
版权所有(c)2014 Matthew Lewis。根据the MIT License授权。