diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/rack.rb | 17 | ||||
-rw-r--r-- | lib/rack/version.rb | 29 |
2 files changed, 31 insertions, 15 deletions
diff --git a/lib/rack.rb b/lib/rack.rb index 751bb059..a40738fb 100644 --- a/lib/rack.rb +++ b/lib/rack.rb @@ -11,22 +11,9 @@ # All modules meant for use in your application are <tt>autoload</tt>ed here, # so it should be enough just to <tt>require 'rack'</tt> in your code. -module Rack - # The Rack protocol version number implemented. - VERSION = [1, 3] - - # Return the Rack protocol version as a dotted string. - def self.version - VERSION.join(".") - end - - RELEASE = "2.2.0" - - # Return the Rack release as a dotted string. - def self.release - RELEASE - end +require_relative 'rack/version' +module Rack HTTP_HOST = 'HTTP_HOST' HTTP_VERSION = 'HTTP_VERSION' HTTPS = 'HTTPS' diff --git a/lib/rack/version.rb b/lib/rack/version.rb new file mode 100644 index 00000000..fa37d786 --- /dev/null +++ b/lib/rack/version.rb @@ -0,0 +1,29 @@ +# frozen_string_literal: true + +# Copyright (C) 2007-2019 Leah Neukirchen <http://leahneukirchen.org/infopage.html> +# +# Rack is freely distributable under the terms of an MIT-style license. +# See MIT-LICENSE or https://opensource.org/licenses/MIT. + +# The Rack main module, serving as a namespace for all core Rack +# modules and classes. +# +# All modules meant for use in your application are <tt>autoload</tt>ed here, +# so it should be enough just to <tt>require 'rack'</tt> in your code. + +module Rack + # The Rack protocol version number implemented. + VERSION = [1, 3] + + # Return the Rack protocol version as a dotted string. + def self.version + VERSION.join(".") + end + + RELEASE = "2.2.0" + + # Return the Rack release as a dotted string. + def self.release + RELEASE + end +end |