1
0
Fork 0
mirror of https://github.com/puma/puma.git synced 2022-11-09 13:48:40 -05:00
puma--puma/lib/puma/detect.rb

24 lines
347 B
Ruby
Raw Normal View History

# frozen_string_literal: true
2012-08-10 22:35:47 -04:00
module Puma
IS_JRUBY = defined?(JRUBY_VERSION)
def self.jruby?
IS_JRUBY
end
IS_WINDOWS = RUBY_PLATFORM =~ /mswin|ming|cygwin/
def self.windows?
IS_WINDOWS
end
def self.mri?
2020-03-09 04:48:10 -04:00
RUBY_ENGINE == 'ruby' || RUBY_ENGINE.nil?
end
2020-04-21 19:33:13 -04:00
def self.forkable?
::Process.respond_to?(:fork)
end
end