diff --git a/lib/forwardable.rb b/lib/forwardable.rb index 91c932913e..7f219235d0 100644 --- a/lib/forwardable.rb +++ b/lib/forwardable.rb @@ -110,10 +110,7 @@ # module Forwardable require 'forwardable/impl' - - # Version of +forwardable.rb+ - VERSION = "1.2.0" - FORWARDABLE_VERSION = VERSION + require "forwardable/version" @debug = nil class << self diff --git a/lib/forwardable/forwardable.gemspec b/lib/forwardable/forwardable.gemspec index f90b82269d..a3c727912f 100644 --- a/lib/forwardable/forwardable.gemspec +++ b/lib/forwardable/forwardable.gemspec @@ -1,8 +1,8 @@ begin - require_relative "lib/forwardable" + require_relative "lib/forwardable/version" rescue LoadError # for Ruby core repository - require_relative "../forwardable" + require_relative "version" end Gem::Specification.new do |spec| diff --git a/lib/forwardable/version.rb b/lib/forwardable/version.rb new file mode 100644 index 0000000000..b0b67a88de --- /dev/null +++ b/lib/forwardable/version.rb @@ -0,0 +1,5 @@ +module Forwardable + # Version of +forwardable.rb+ + VERSION = "1.2.0" + FORWARDABLE_VERSION = VERSION +end