Heroku toolbelt未被OSX认可

时间:2014-02-21 01:29:11

标签: ruby-on-rails heroku command-line

我已经尝试安装并重新安装Heroku工具带大约10次,但我似乎无法弄清楚如何正确安装它。我尝试过多次删除和添加ssh密钥以及许多其他stackoverflow解决方案,但不知道从哪里开始。由于我对命令行非常基本的了解,因此我很难受到任何帮助。

$ heroku # or heroku login, heroku help, etc.
fatal: 'heroku' does not appear to be a git repository
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

$ which heroku
/usr/bin/heroku

这是该文件的内容

#!/usr/local/heroku/ruby/bin/ruby
# encoding: UTF-8

# resolve bin path, ignoring symlinks
require "pathname"
bin_file = Pathname.new(__FILE__).realpath

# add locally vendored gems to libpath
gem_dir = File.expand_path("../../vendor/gems", bin_file)
Dir["#{gem_dir}/**/lib"].each do |libdir|
  $:.unshift libdir
end

# add self to libpath
$:.unshift File.expand_path("../../lib", bin_file)

# inject any code in ~/.heroku/client over top
require "heroku/updater"
Heroku::Updater.inject_libpath

# start up the CLI
require "heroku/cli"
Heroku.user_agent = "heroku-toolbelt/#{Heroku::VERSION} (#{RUBY_PLATFORM}) ruby/#{RUBY_VERSION}"
Heroku::CLI.start(*ARGV)

bashrc中     export PATH =“/ usr / local / heroku / bin:$ PATH”

1 个答案:

答案 0 :(得分:0)

别名“push heroku”阻止了工具带被调用。删除它可以使heroku命令正常工作,然后可以正确设置。