瀏覽代碼

use curl for install_script if available

pull/1/head
10sr 12 年之前
父節點
當前提交
5d8b23c798
共有 1 個檔案被更改,包括 9 行新增2 行删除
  1. +9
    -2
      bashrc

+ 9
- 2
bashrc 查看文件

@@ -388,8 +388,15 @@ _my_install_script(){
do
bn=$(basename "$f")
type $bn >/dev/null 2>&1 || {
wget "$f" -P "$HOME/bin/" &&
chmod u+x "$HOME/bin/${bn}"
if type wget >/dev/null 2>&1
then
wget "$f" -P "$HOME/bin/" &&
chmod u+x "$HOME/bin/${bn}"
elif type curl >/dev/null 2>&1
then
curl --url "$f" --output "$HOME/bin/${bn}" &&
chmod u+x "$HOME/bin/${bn}"
fi
}
done
}


Loading…
取消
儲存