I am trying to get a development environment created on a new machine and getting stuck on connecting to heroku. I downloaded and installed the cli, and heroku -v shows I have the most updated version. My folder structure is Users/tombrown/projects. When I manually create a new directory under projects, the new sub-directory also has the cli installed, but when I git clone or heroku git:clone, the new sub-directory indicates there is no cli installed.
Thomass-MacBook:projects tombrown$ heroku -v
heroku/7.16.0 darwin-x64 node-v10.10.0
Thomass-MacBook:projects tombrown$ heroku git:clone -a livebytransit
Cloning into 'livebytransit'...
remote: Counting objects: 4814, done.
remote: Compressing objects: 100% (1579/1579), done.
remote: Total 4814 (delta 3276), reused 4564 (delta 3087)
Receiving objects: 100% (4814/4814), 15.68 MiB | 5.75 MiB/s, done.
Resolving deltas: 100% (3276/3276), done.
Thomass-MacBook:projects tombrown$ cd livebytransit
Thomass-MacBook:livebytransit tombrown$ heroku -v
Install the Heroku CLI from https://cli.heroku.com
Thomass-MacBook:livebytransit tombrown$ rm -rf livebytransit
Thomass-MacBook:livebytransit tombrown$ cd ..
Thomass-MacBook:projects tombrown$ ls
livebytransit
Thomass-MacBook:projects tombrown$ rm -rf livebytransit
Thomass-MacBook:projects tombrown$ ls
Thomass-MacBook:projects tombrown$ git clone https://github.com/tom-brown/LiveByTransit.git
Cloning into 'LiveByTransit'...
remote: Counting objects: 4820, done.
remote: Compressing objects: 100% (59/59), done.
remote: Total 4820 (delta 38), reused 50 (delta 23), pack-reused 4737
Receiving objects: 100% (4820/4820), 15.35 MiB | 6.14 MiB/s, done.
Resolving deltas: 100% (3285/3285), done.
Thomass-MacBook:projects tombrown$ cd LiveByTransit
Thomass-MacBook:LiveByTransit tombrown$ git init
Reinitialized existing Git repository in /Users/tombrown/projects/LiveByTransit/.git/
Thomass-MacBook:LiveByTransit tombrown$ git add .
Thomass-MacBook:LiveByTransit tombrown$ git commit -m "kind of first commit"
On branch master
Your branch is up to date with 'origin/master'.
nothing to commit, working tree clean
Thomass-MacBook:LiveByTransit tombrown$ heroku git:remote -a livebytransit
Install the Heroku CLI from https://cli.heroku.com
Has anyone run into this issue? I don't see anything similar in heroku help or stackoverflow.
Per the suggestion in the first comment below, the output of which heroku
and type heroku
both provide a big hint. Something is wrong with the path.
Thomass-MacBook:LiveByTransit tombrown$ which heroku
/Users/tombrown/.rvm/gems/ruby-2.3.1/bin/heroku
Thomass-MacBook:LiveByTransit tombrown$ type heroku
heroku is /Users/tombrown/.rvm/gems/ruby-2.3.1/bin/heroku
Thomass-MacBook:LiveByTransit tombrown$ cd ..
Thomass-MacBook:projects tombrown$ which heroku
/usr/local/bin/heroku
Thomass-MacBook:projects tombrown$ type heroku
heroku is /usr/local/bin/heroku
Thomass-MacBook:projects tombrown$
It looks like you have the legacy heroku
Gem installed in your Ruby 2.3.1 RVM gemset. When that Ruby environment is active this will shadow the system-installed, modern heroku
CLI.
With your ~/.rvm/gems/ruby-2.3.1
environment active, remove the legacy Gem by running gem uninstall heroku
.