2014-02-21 53 views
0

我試過安裝並重新安裝Heroku toolbelt約10次,但我似乎無法弄清楚如何正確安裝它。我試過多次刪除和添加ssh密鑰以及許多其他的stackoverflow解決方案,但不知道從哪裏去。任何幫助將不勝感激,因爲我由於對命令行的基本理解而陷入困境。Heroku toolbelt未被識別OSX

$ 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 出口路徑的內容= 「在/ usr /本地/ Heroku的/ bin中:$ PATH」

+0

如果你在mac osx上,爲什麼不直接使用他們的安裝程序?https://toolbelt.heroku.com/會爲你做的一切嗎? –

+0

這正是我用它,並沒有在我的新電腦(macbook air mavericks)出於某種原因我無法弄清楚。我的最後一個安裝非常簡單。 – avalente1

+1

你的第3行表明鍵入「heroku」似乎試圖打開一些git repo,你有一些別名是阻礙嗎? –

回答

0

「推的Heroku」 的別名正在阻止工具帶被調用。刪除這使得heroku命令正常工作,然後可以進行正確的設置。