1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

[ruby/erb] Let ERB.version just return a version

and deprecate ERB::Revision.

`'$Date::                           $'` has not been working since Git
migration from SVN. I'm sorry.

Because it has been already broken, I'd like to take this opportunity to
make `ERB.version` compatible with `Gem::Version.new`.

https://github.com/ruby/erb/commit/2b4182eb10
This commit is contained in:
Takashi Kokubun 2021-01-20 22:24:02 -08:00 committed by git
parent f766ba54a9
commit b12bd451af

View file

@ -258,10 +258,11 @@ require 'erb/version'
#
class ERB
Revision = '$Date:: $' # :nodoc: #'
deprecate_constant :Revision
# Returns revision information for the erb.rb module.
def self.version
"erb.rb [#{VERSION} #{ERB::Revision.split[1]}]"
VERSION
end
end