我使用宝石来思考狮身人面像:
sudo gem install freelancing-god-thinking-sphinx \
--source http://gems.github.com
所以:
require 'vendor/plugins/thinking-sphinx/recipes/thinking_sphinx'
网站上规定的内容不起作用。
使用 gem 时,如何在我的 deploy.rb 文件中包含 capistrano thinking sphinx 任务?
编辑
添加:require 'thinking_sphinx/deploy/capistrano'
给我:
/usr/lib/ruby/gems/1.8/gems/freelancing-god-thinking-sphinx-1.1.12/lib/thinking_sphinx/deploy/capistrano.rb:1:main:Object 的未定义方法“命名空间”(NoMethodError) 来自 /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:36:in `gem_original_require' 来自 /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:36:in `require' 来自 /usr/lib/ruby/gems/1.8/gems/capistrano-2.5.8/lib/capistrano/configuration/loading.rb:152:in `require'