Fixed Guard::Version in ruby 1.8.7

This commit is contained in:
Thibaud Guillaume-Gentil 2011-06-08 09:10:26 +02:00
parent 71e51706b7
commit a2b3927a2e
3 changed files with 5 additions and 5 deletions

View File

@ -14,7 +14,7 @@ namespace(:spec) do
system "cmd /c echo -----------#{version}------------ & " + system "cmd /c echo -----------#{version}------------ & " +
"pik use #{version} & " + "pik use #{version} & " +
"bundle install & " + "bundle install & " +
"rake spec" "bundle exec rake spec"
end end
end end
else else
@ -26,9 +26,9 @@ namespace(:spec) do
rvm #{version}; rvm #{version};
echo "--------- version #{version} ----------\n"; echo "--------- version #{version} ----------\n";
bundle install; bundle install;
rake spec' bundle exec rake spec'
BASH BASH
end end
end end
end end
end end

View File

@ -84,7 +84,7 @@ module Guard
try_require = false try_require = false
const_name = name.to_s.downcase.gsub('-', '') const_name = name.to_s.downcase.gsub('-', '')
begin begin
require "guard/#{name.downcase}" if try_require require "guard/#{name.to_s.downcase}" if try_require
self.const_get(self.constants.find {|c| c.to_s.downcase == const_name }) self.const_get(self.constants.find {|c| c.to_s.downcase == const_name })
rescue TypeError rescue TypeError
unless try_require unless try_require

View File

@ -1,3 +1,3 @@
module Guard module Guard
VERSION = "0.4.1" unless defined? VERSION VERSION = "0.4.1" unless defined? Guard::VERSION
end end