我最近把我的ubuntu换成了Linux mint,所以我需要重新安装我的宝石,但是它给了我这个错误.
步骤我已经完成了
Fetching git://github.com/seuros/capistrano-puma.git
error: cannot open .git/FETCH_HEAD: Permission denied
Retrying git fetch --force --quiet --tags
"/home/asad/.bundler/cache/git/capistrano-puma-e90ae8bdcca081264c0ff67caa1d11e89f7a01e0" due to error (2/3): Bundler::Source::Git::GitCommandError Git error: command `git fetch --force --quiet --tags "/home/asad/.bundler/cache/git/capistrano-puma-e90ae8bdcca081264c0ff67caa1d11e89f7a01e0"` in directory /usr/local/rvm/gems/ruby-2.0.0-p598/bundler/gems/capistrano-puma-7748efb9a53d has failed.
If this error persists you could try removing the cache directory '/home/asad/.bundler/cache/git/capistrano-puma-e90ae8bdcca081264c0ff67caa1d11e89f7a01e0'
error: cannot open .git/FETCH_HEAD: Permission denied
Retrying git fetch --force --quiet --tags "/home/asad/.bundler/cache/git/capistrano-puma-e90ae8bdcca081264c0ff67caa1d11e89f7a01e0" due to error (3/3): Bundler::Source::Git::GitCommandError Git error: command `git fetch --force --quiet --tags "/home/asad/.bundler/cache/git/capistrano-puma-e90ae8bdcca081264c0ff67caa1d11e89f7a01e0"` in directory /usr/local/rvm/gems/ruby-2.0.0-p598/bundler/gems/capistrano-puma-7748efb9a53d has failed.
If this error persists you could try removing the cache directory '/home/asad/.bundler/cache/git/capistrano-puma-e90ae8bdcca081264c0ff67caa1d11e89f7a01e0'
error: cannot open .git/FETCH_HEAD: Permission denied
Git error: command `git fetch --force --quiet --tags "/home/asad/.bundler/cache/git/capistrano-puma-e90ae8bdcca081264c0ff67caa1d11e89f7a01e0"` in directory
/usr/local/rvm/gems/ruby-2.0.0-p598/bundler/gems/capistrano-puma-7748efb9a53d has failed.
If this error persists you could try removing the cache directory '/home/asad/.bundler/cache/git/capistrano-puma-e90ae8bdcca081264c0ff67caa1d11e89f7a01e0'发布于 2015-12-15 00:32:49
如果您使用的是rvm,请从命令行运行:
~> rvm fix-permissions这为我解决了那种错误。
发布于 2015-05-01 15:35:19
bundle exec bundle install为我工作过。当我作为root登录时,我犯了安装ruby的错误,所以我现在必须这样做,直到我解决了问题。
发布于 2015-04-16 10:13:41
我在升级班德勒的时候也遇到了同样的问题.原来,包系统安装位置中的缓存目录导致了这个问题。彻底清除这个问题--这是在OSX上,不是使用RVM,而是10.10.3上的标准OSX ruby。
https://stackoverflow.com/questions/27416849
复制相似问题