安装gem时出现此错误:“错误:执行gem时(Zlib :: GzipFile :: Error)” [英] I get this error when installing a gem: "ERROR: While executing gem ... (Zlib::GzipFile::Error)"

查看:131
本文介绍了安装gem时出现此错误:“错误:执行gem时(Zlib :: GzipFile :: Error)”的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


可能存在重复:

错误:执行gem时...(Zlib :: GzipFile :: Error)不是gzip格式


在我的系统上安装gem时,出现以下错误:

  gem install blackbook --version> = 1.0.7--source http://github.com/tamoyal/blackbook/tree/master 
错误:执行gem时...( Zlib :: GzipFile :: Error)
不是gzip格式

这是怎么回事?我创建了宝石,所以也许它是我的宝石构建错了?



谢谢

解决方案<



尝试 gem fetch -V

$ c

$ $ p
steve @ macpro:〜$ gem fetch blackbook --version> = 1.0.7--source http:/ / /github.com/tamoyal/blackbook/tree/master -V
GET 301永久移动:http://github.com/tamoyal/blackbook/tree/master/specs.4.8.gz
GET 200 OK:http://github.com/tamoyal/blackbook/tree/master/
错误:执行gem时...(Zlib :: GzipFile :: Error)
不是gzip格式

由于 gem 无法获取,因此您收到not in gzip format错误 specs.4.8.gz 。 GitHub将301重定向返回到您的项目主页,这当然不是它想要的,也不是gzip。



对不起,我不能帮你进一步,但我没有在GitHub上创建一个gem,更少。


Possible Duplicate:
ERROR: While executing gem … (Zlib::GzipFile::Error) not in gzip format

When installing a gem on my system, I get the following error:

gem install blackbook --version ">= 1.0.7" --source http://github.com/tamoyal/blackbook/tree/master
ERROR:  While executing gem ... (Zlib::GzipFile::Error)
    not in gzip format

Any ideas as to why this is happening? I built the gem so maybe it is something wrong with my gem build?

Thanks

解决方案

Something isn't set up properly to fetch the gem from GitHub.

try gem fetch -V

steve@macpro:~$ gem fetch blackbook --version ">= 1.0.7" --source http://github.com/tamoyal/blackbook/tree/master -V
GET 301 Moved Permanently: http://github.com/tamoyal/blackbook/tree/master/specs.4.8.gz
GET 200 OK: http://github.com/tamoyal/blackbook/tree/master/
ERROR:  While executing gem ... (Zlib::GzipFile::Error)
    not in gzip format

You're getting the "not in gzip format" error because gem can't fetch specs.4.8.gz. GitHub returns a 301 redirect back to your project home page, which of course isn't what it wants and isn't gzipped.

Sorry I can't help you further, but I haven't build a gem, much less on GitHub.

这篇关于安装gem时出现此错误:“错误:执行gem时(Zlib :: GzipFile :: Error)”的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆