summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorTakashi Kokubun <takashikkbn@gmail.com>2021-01-20 22:24:02 -0800
committergit <svn-admin@ruby-lang.org>2021-01-21 15:26:55 +0900
commitb12bd451af693259fc1f22c398e1065029acb098 (patch)
treef34056f3a5b09c5ea063cc0042ac55a28c4f0ec8 /lib
parentf766ba54a9e25239ecc28a623c95e85bb6ac45ea (diff)
[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
Diffstat (limited to 'lib')
-rw-r--r--lib/erb.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/erb.rb b/lib/erb.rb
index 48e0505157..17dc557929 100644
--- a/lib/erb.rb
+++ b/lib/erb.rb
@@ -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