Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/ruby-on-rails-3/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Ruby on rails 无法在dev box上从github安装gem_Ruby On Rails_Ruby On Rails 3_Github_Gem_Bundler - Fatal编程技术网

Ruby on rails 无法在dev box上从github安装gem

Ruby on rails 无法在dev box上从github安装gem,ruby-on-rails,ruby-on-rails-3,github,gem,bundler,Ruby On Rails,Ruby On Rails 3,Github,Gem,Bundler,我有一个gem文件,可以在本地正常工作。在我的gem文件中,我的一个gem使用github位置安装,如下所示 gem 'rails3-jquery-autocomplete', :git => 'https://github.com/willfults/rails3-jquery-autocomplete.git' 问题是,当我在我的dev box中运行ssh并运行bundle或bundle安装时,我在服务器上遇到以下错误 Fetching gem metadata from https

我有一个gem文件,可以在本地正常工作。在我的gem文件中,我的一个gem使用github位置安装,如下所示

gem 'rails3-jquery-autocomplete', :git => 'https://github.com/willfults/rails3-jquery-autocomplete.git'
问题是,当我在我的dev box中运行ssh并运行bundle或bundle安装时,我在服务器上遇到以下错误

Fetching gem metadata from https://rubygems.org/..
Fetching https://github.com/willfults/rails3-jquery-autocomplete.git
fatal: failed to open '/srv/www/socialu.com/https://github.com/willfults/rails3-jquery-autocomplete.git/objects': No such file or directory
Git error: command `git clone 'https://github.com/willfults/rails3-jquery-autocomplete.git' "/srv/www/socialu.com/https:/github.com/willfults/rails3-jquery-autocomplete.git/ruby/1.9.1/cache/bundler/git/rails3-jquery-autocomplete-186d8dd59401e0d4dd8c2860261d9ba55e0793f2" --bare --no-hardlinks` in directory /srv/www/socialu.com has failed.
我如何解决这些问题?谢谢

更新:通过git url,我得到以下信息

吸引git://github.com/willfults/rails3-jquery-autocomplete.git 远程:计数对象:1846,完成。远程:压缩对象: 100%(784/784),完成。远程:总计1846(增量1072),重复使用1688 (delta 957)接收对象:100%(1846/1846),481.07千磅| 764 KiB/s,完成。解析增量:100%(1072/1072),完成。宋承宪:不能 解析主机名/srv/www/socialu.com/https:名称或服务未知 致命:远程端意外挂起Git错误:command
Git
克隆--不签出
“/srv/www/socialu.com/https:/github.com/willfults/rails3 jquery autocomplete.git/ruby/1.9.1/cache/bundler/git/rails3-jquery-autocomplete-6e048304dc5207eafc457581b1fa2d0073d2e1ed”
“/srv/www/socialu.com/https:/github.com/willfults/rails3 jquery autocomplete.git/ruby/1.9.1/bundler/gems/rails3-jquery-autocomplete-060f2bea5e46”
在目录/srv/www/socialu.com中失败。如果此错误仍然存在 您可以尝试删除缓存目录 “/srv/www/socialu.com/https:/github.com/willfults/rails3 jquery autocomplete.git/ruby/1.9.1/cache/bundler/git/rails3-jquery-autocomplete-6e04304dc52207eafc457581b1fa2d0073d2e1ed”


这是一个路径问题,因为您可以看到URL与文件夹路径混合在一起。 尝试使用git://URL而不是https://

不确定它是否会起作用,但它在某个地方是一个路径问题

还要检查服务器上的rubygems版本,并根据需要进行更新(最新版本为v1.8.24)。如果您的机器按原样工作,则会出现一些不同的情况

gem -v

希望对您有所帮助。

谢谢您尝试了rubygems升级,未解决的问题将在下一步尝试git path并让您知道。git url也未解决,尽管它在本地再次工作。得到一个不同的错误,虽然将张贴…嗯,这是一个进步!我将检查下一个问题:)虽然这并没有解决我的问题,但我接受这个答案是因为努力+它可能会帮助其他人。此外,我还通过将我的gem添加到rubygems.org来解决这个问题,因此没有从github中提取。