Sha256: 1f0bbfaa77ab59bd2238c075ade663a8ab9502bd629bc6b4763292ee1d4aba3a

Contents?: true

Size: 414 Bytes

Versions: 1

Compression:

Stored size: 414 Bytes

Contents

# encoding: utf-8

module Rango
  class Platform
    class << self
      def match?(platform)
        !! RUBY_PLATFORM.match(/#{platform}/i)
      end

      def windows?
        self.match?("mswin|mingw")
      end

      def linux?
        self.match?("linux")
      end

      def macosx?
        self.match?("-darwin")
      end

      def unix?
        self.linux? or self.macosx?
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
rango-0.0.4 lib/rango/ext/platform.rb