Ruby on Rails - unable to convert “\\x89” from ASCII-8BIT to UTF-8 for xxx/xxxx/xxxx

匿名 (未验证) 提交于 2019-12-03 01:58:03

问题:

I am installing ruby on rails 4.0.0 on my linux system , but i am getting this kind of errors unable to convert "\x89" from ASCII-8BIT to UTF8 for guides/assets/images/getting_started/routing_error_no_route_matches.png, skipping and many similar errors , i read here that it won't cause any effect ,but i do not understand why it is coming . Any pointers?

回答1:

You need to update / install a version of the rdoc gem that supports the conversion. Then these errors won't appear during generation of the documentation when you install rails or when you regenerate the documentation.

gem install rdoc 

Then to regenerate the documentation

gem rdoc --all --overwrite 


回答2:

Set such environment variables before you do install:

export LANGUAGE=en_US.UTF-8 export LANG=en_US.UTF-8 export LC_ALL=en_US.UTF-8 


回答3:

If you prefer using online documentation to using rdoc and ri, then you can avoid these errors and speed up your installs by skipping the rdoc and ri installations. Michael Hartl recommends this in his book. Just add a .gemrc file to your home directory with the following contents:

install: --no-rdoc --no-ri update: --no-rdoc --no-ri 


标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!