Ubuntu 13.10安装heroku toolbelt异常解决方案

heroku toolbelt是heroku的客户端程序包,包括Heroku client,Foreman和Git

heroku官网提供的安装方式是:wget -qO- https://toolbelt.heroku.com/install-ubuntu.sh | sh

但是在ubuntu 13.10下直接安装会报错,提示:

sh: 7: [[: not found

解决方案为将https://toolbelt.heroku.com/install-ubuntu.sh wget至本地,修改第13行
将deb http://toolbelt.heroku.com/ubuntu的http更改为https


#!/bin/sh
{
    echo "This script requires superuser access to install apt packages."
    echo "You will be prompted for your password by sudo."

    # clear any previous sudo permission
    sudo -k

    # run inside sudo
    sudo sh <<SCRIPT

  # add heroku repository to apt
  echo "deb http://toolbelt.heroku.com/ubuntu ./" > /etc/apt/sources.list.d/heroku.list #将http更换为https

  # install heroku's release key for package verification
  wget -O- https://toolbelt.heroku.com/apt/release.key | apt-key add -

  # update your sources
  apt-get update

  # install the toolbelt
  apt-get install -y heroku-toolbelt

SCRIPT
}

执行sudo sh ./ install-ubuntu.sh即可完成安装

本文链接:http://bookshadow.com/weblog/2014/05/06/ubuntu-1310-heroku-toolbelt/
请尊重作者的劳动成果,转载请注明出处!书影博客保留对文章的所有权利。

如果您喜欢这篇博文,欢迎您捐赠书影博客: ,查看支付宝二维码