Question

I need to install heroku-toolbelt without sudo. I am trying to install it in virtual env. I modified install.sh file (changed paths)

> #!/bin/bash {
>     HEROKU_CLIENT_URL="https://s3.amazonaws.com/assets.heroku.com/heroku-client/heroku-client.tgz"
> 
>     echo "This script requires superuser access to install software."
>     echo "You will be prompted for your password by sudo."
> 
>     # clear any previous sudo permission
>     #sudo -k
> 
>     # run inside sudo
>     #sudo sh <<SCRIPT
> 
>   # download and extract the client tarball   rm -rf
> /users/user/Documents/mypy/usr/local/heroku   mkdir -p
> /users/user/Documents/mypy/usr/local/heroku   cd
> /users/user/Documents/mypy/usr/local/heroku
> 
>   if [[ -z "$(which wget)" ]]; then
>     curl -s $HEROKU_CLIENT_URL | tar xz   else
>     wget -qO- $HEROKU_CLIENT_URL | tar xz   fi
> 
>   mv heroku-client/* .   rmdir heroku-client
> 
> SCRIPT
> 
>     # remind the user to add to $PATH
>     if [[ ":$PATH:" != *":/users/user/Documents/mypy/usr/local/heroku/bin:"* ]]; then     echo "Add the Heroku CLI to your PATH using:"   echo "$ echo
> 'PATH=\"/users/user/Documents/mypy/usr/local/heroku/bin:\$PATH\"' >>
> ~/.profile"
>     fi
> 
>     echo "Installation complete" }

But the script is not working.

Était-ce utile?

La solution

I had a similar issue when installing the tool belt in a unbuntu vitural env using PuTTY as the SSH. Before I installed I used the command sudo -k to clear permissions before pasting the link. I know that should not be an issue since it is int he script but it worked. I hope it helps.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top