ruby --disable-gems -S update_rubygems
3、NoMethodError: undefined method `spec' for nil:NilClass
An error occurred while installing carrierwave (0.11.0), and Bundler cannot continue.
Make sure that `gem install carrierwave -v '0.11.0'` succeeds before bundling.gem
gem uninstall bundler
gem install bundler 就是安装新版的bundler
4、.rvm/wrappers/ruby-2.1.5/rake nginx:clean nginx RELEASE=yes
rake aborted!
LoadError: cannot load such file -- rubygems/builder
gem install passenger --version 4.0.0.rc6
5、%u转化为汉字的问题:
如:迷恋你娘 %u8FF7%u604B%u4F60%u5A18
s = "%u8FF7%u604B%u4F60%u5A18"
b = s.split("%u")-[""]
b.map{|t| [t.to_i(16)].pack("U")}.join
6、Bundler::GemspecError: Could not read gem at /XXX-1.8.2.gem. It may be corrupted.
删除cache里的文件,重新bundle install
7、国际化时如果有目录,配置文件的写法也是用目录形式,比如: admin/user: