Method: Kernel#is_mac?

Defined in:
lib/openc3/core_ext/kernel.rb

#is_mac?Boolean

Returns Whether the current platform is Mac.

Returns:

  • (Boolean)

    Whether the current platform is Mac



31
32
33
34
35
36
37
38
# File 'lib/openc3/core_ext/kernel.rb', line 31

def is_mac?
  _, platform, *_ = RUBY_PLATFORM.split("-")
  result = false
  if /darwin/.match?(platform)
    result = true
  end
  return result
end