Class: Buildbox::Platform

Inherits:
Object
  • Object
show all
Defined in:
lib/buildbox/platform.rb

Class Method Summary collapse

Class Method Details

.platformObject



18
19
20
# File 'lib/buildbox/platform.rb', line 18

def platform
  RbConfig::CONFIG["host_os"].downcase
end

.windows?Boolean

Returns:

  • (Boolean)


10
11
12
13
14
15
16
# File 'lib/buildbox/platform.rb', line 10

def windows?
  %W[mingw mswin].each do |text|
    return true if platform.include?(text)
  end

  false
end