Sha256: d10d742aa8f0bd070347e8f6629af10b24af7fa494dd21df07848818ea5bb29d

Contents?: true

Size: 610 Bytes

Versions: 18

Compression:

Stored size: 610 Bytes

Contents

### Platform check regexes

module Echoe::Platform
  def self.windows?
    @windows ||= RUBY_PLATFORM =~ /djgpp|(cyg|ms|bcc)win|mingw/
    !@windows.nil?
  end

  def self.gcc?
    @gcc ||= RUBY_PLATFORM =~ /mingw/
    !@gcc.nil?
  end

  def self.msvc?
    @msvc ||= RUBY_PLATFORM =~ /mswin/
    !@msvc.nil?
  end

  def self.java?
    @java ||= RUBY_PLATFORM =~ /java/
    !@java.nil?
  end

  def self.suffix
    Gem.default_exec_format =~ /%s(.*)/
    @suffix ||= $1
  end

  def self.rake
    windows? ? "rake#{suffix}.bat" : "rake#{suffix}"
  end

  def self.make
    msvc? ? 'nmake' : 'make'
  end
end

Version data entries

18 entries across 12 versions & 3 rubygems

Version Path
ric-0.14.2 vendor/bundle/ruby/2.7.0/gems/echoe-4.6.6/lib/echoe/platform.rb
ric-0.14.2 vendor/bundle/ruby/2.7.0/gems/echoe-4.6.3/lib/echoe/platform.rb
ric-0.14.2 vendor/bundle/ruby/2.7.0/gems/echoe-4.6.5/lib/echoe/platform.rb
ric-0.14.1 vendor/bundle/ruby/2.7.0/gems/echoe-4.6.6/lib/echoe/platform.rb
ric-0.14.1 vendor/bundle/ruby/2.7.0/gems/echoe-4.6.5/lib/echoe/platform.rb
ric-0.14.1 vendor/bundle/ruby/2.7.0/gems/echoe-4.6.3/lib/echoe/platform.rb
ric-0.14.0 vendor/bundle/ruby/2.7.0/gems/echoe-4.6.5/lib/echoe/platform.rb
ric-0.14.0 vendor/bundle/ruby/2.7.0/gems/echoe-4.6.3/lib/echoe/platform.rb
ric-0.14.0 vendor/bundle/ruby/2.7.0/gems/echoe-4.6.6/lib/echoe/platform.rb
ric-0.13.0 vendor/bundle/ruby/2.5.0/gems/echoe-4.6.6/lib/echoe/platform.rb
ric-0.12.2 vendor/bundle/ruby/2.5.0/gems/echoe-4.6.6/lib/echoe/platform.rb
echoe-4.6.6 lib/echoe/platform.rb
echoe-4.6.5 lib/echoe/platform.rb
horseman-0.0.5 vendor/ruby/1.9.1/gems/echoe-4.6.3/lib/echoe/platform.rb
horseman-0.0.4 vendor/ruby/1.9.1/gems/echoe-4.6.3/lib/echoe/platform.rb
horseman-0.0.3 vendor/ruby/1.9.1/gems/echoe-4.6.3/lib/echoe/platform.rb
horseman-0.0.2 vendor/ruby/1.9.1/gems/echoe-4.6.3/lib/echoe/platform.rb
echoe-4.6.3 lib/echoe/platform.rb