■
ruby1.9 + merb は鬼門,動かない
*** abstract_controller.rb 2008-11-29 17:12:08.000000000 +0900 --- /opt/local/lib/ruby1.9/gems/1.9.1/gems/merb-core-1.0.3/lib/merb-core/controller/abstract_controller.rb 2008-11-29 16:27:55.000000000 +0900 *************** *** 414,421 **** # :api: private def _evaluate_condition(condition) case condition ! when Symbol : self.send(condition) ! when Proc : self.instance_eval(&condition) else raise ArgumentError, 'Filter condtions need to be either a Symbol or a Proc' --- 414,421 ---- # :api: private def _evaluate_condition(condition) case condition ! when Symbol then self.send(condition) ! when Proc then self.instance_eval(&condition) else raise ArgumentError, 'Filter condtions need to be either a Symbol or a Proc'
*** merb-gen.rb 2008-11-29 17:14:49.000000000 +0900 --- /opt/local/lib/ruby1.9/gems/1.9.1/gems/merb-gen-1.0.3/lib/merb-gen.rb 2008-11-29 16:30:15.000000000 +0900 *************** *** 1,6 **** require 'rubygems' require 'merb-core' ! require 'sha1' gem 'templater', '>= 0.3.2' require 'templater' --- 1,6 ---- require 'rubygems' require 'merb-core' ! require 'digest/sha1' gem 'templater', '>= 0.3.2' require 'templater'
*** string.rb 2008-11-29 17:16:26.000000000 +0900 --- /opt/local/lib/ruby1.9/gems/1.9.1/gems/templater-0.5.0/lib/templater/core_ext/string.rb 2008-11-29 16:40:33.000000000 +0900 *************** *** 2,8 **** def realign_indentation basis = self.index(/\S/) # find the first non-whitespace character ! return self.to_a.map { |s| s[basis..-1] }.join end end --- 2,8 ---- def realign_indentation basis = self.index(/\S/) # find the first non-whitespace character ! return Array(self).map { |s| s[basis..-1] }.join end end
*** init.rb 2008-11-29 17:18:27.000000000 +0900 --- /opt/local/lib/ruby1.9/gems/1.9.1/gems/merb-gen-1.0.3/lib/generators/templates/application/merb_stack/config/init.rb 2008-11-29 17:08:29.000000000 +0900 *************** *** 11,17 **** c[:session_store] = 'cookie' # can also be 'memory', 'memcache', 'container', 'datamapper # cookie session store configuration ! c[:session_secret_key] = '<%= SHA1.new(rand(100000000000).to_s).to_s %>' # required for cookie session store c[:session_id_key] = '_<%= base_name %>_session_id' # cookie session id key, defaults to "_session_id" end --- 11,17 ---- c[:session_store] = 'cookie' # can also be 'memory', 'memcache', 'container', 'datamapper # cookie session store configuration ! c[:session_secret_key] = '<%= Digest::SHA1.hexdigest(rand(100000000000).to_s) %>' # required for cookie session store c[:session_id_key] = '_<%= base_name %>_session_id' # cookie session id key, defaults to "_session_id" end