错误:执行gem时(Zlib :: GzipFile :: Error)不是gzip格式 [英] ERROR: While executing gem ... (Zlib::GzipFile::Error) not in gzip format

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

问题描述

我正在开发一个Sencha touch 2应用程序。我一直在关注设计Sencha Touch应用程序的用户界面关于secha touch应用程序主题的教程。



它需要我安装Ruby,Compass和SASS。
我使用rubyinstaller.org的安装程序安装了Ruby。



在执行以下命令时,我得到预期结果,确认安装正确:

  C:\> ruby​​ -v 

ruby​​ 1.9.3p327(2012-11-10)[i386
$ / code>

当前来源是最新的:

  C:\>宝石来源

**当前来源**

http://rubygems.org /

接下来,由于我在代理之后,我使用以下命令来安装HAML / Compass:

  C:\> gem install -p [proxy:port]指南针

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

有人可以帮助我吗?我找到了系统更新,宝石来源更新等解决方案,但系统中的所有内容都是最新的。




编辑:

  C:\> gem install compass 

在我的私人系统上工作得很好。当我从我的工作场所尝试相同的命令时,我需要使用上面提到的代理,并导致错误。 解决方案

我假设发生了错误,因为我工作场所的网络感觉会阻止这些下载。



解决方案:我下载了所需的宝石: chunky_png ,fssm,指南针,sass,haml 等。直接从 http://rubygems.org/gems并将这些宝石放在我的本地目录中。

在此之后,我尝试了 gem install compass 。这首先搜索你的本地目录。在找到所需的宝石时,进行安装。不需要连接到ruby网站。



注意:从宝石所在的路径运行命令



<例如:我把宝石放在C:\Ruby193\lib\ruby\gems\1.9.1\gems



所以我跑以下命令:



C:\Ruby193\lib\ruby\gems\1.9.1\gems> gem install指南针


I am developing a Sencha touch 2 application. I have been following the "Styling the user interface of a Sencha Touch application" tutorial on theming of secha touch applications.

It requires me to install Ruby, Compass and SASS. I installed Ruby using the installer from rubyinstaller.org.

On executing the following command, I get the expected result which confirms correct installation:

C:\>ruby -v

ruby 1.9.3p327 (2012-11-10) [i386-mingw32]

Current source is up to date:

C:\>gem sources

** CURRENT SOURCES **

http://rubygems.org/

Next, since I am behind a proxy, I used the following command to install HAML/Compass:

C:\>gem install -p [proxy:port] compass

ERROR:  While executing gem ... (Zlib::GzipFile::Error)
not in gzip format**

Can someone help me? I found solutions such as system update, gem sources update, but everything is up to date on my system.


Edit:

C:\>gem install compass

works perfectly fine on my private system. When I try the same command from my workplace I need to use the proxy as mentioned above and that results in an error.

解决方案

I assume the ERROR occurs since the web sense at my workplace blocks these downloads.

Solution: I downloaded the required gems: chunky_png, fssm, compass, sass, haml etc.. directly from http://rubygems.org/gems and placed these gems in my local directory.

After this I tried gem install compass. This first searches your local directory. On finding the required gems, installation takes place. Does not require connection to the ruby website.

Note: Run the command from the path where the gems are located

eg: I have placed the gems in C:\Ruby193\lib\ruby\gems\1.9.1\gems

So I run the following command :

C:\Ruby193\lib\ruby\gems\1.9.1\gems>gem install compass

这篇关于错误:执行gem时(Zlib :: GzipFile :: Error)不是gzip格式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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