Module: OS

Defined in:
Library/Homebrew/os.rb,
Library/Homebrew/os/mac.rb,
Library/Homebrew/os/mac/sdk.rb,
Library/Homebrew/os/mac/xcode.rb,
Library/Homebrew/os/linux/glibc.rb,
Library/Homebrew/os/mac/version.rb,
Library/Homebrew/os/mac/xquartz.rb,
Library/Homebrew/cask/lib/hbc/macos.rb

Defined Under Namespace

Modules: Linux, Mac

Constant Summary collapse

ISSUES_URL =
"https://github.com/Linuxbrew/brew/wiki/troubleshooting".freeze
PATH_OPEN =
"xdg-open".freeze

Class Method Summary collapse

Class Method Details

.linux?Boolean



9
10
11
12
# File 'Library/Homebrew/os.rb', line 9

def self.linux?
  return false if ENV["HOMEBREW_TEST_GENERIC_OS"]
  RbConfig::CONFIG["host_os"].include? "linux"
end

.mac?Boolean



4
5
6
7
# File 'Library/Homebrew/os.rb', line 4

def self.mac?
  return false if ENV["HOMEBREW_TEST_GENERIC_OS"]
  RbConfig::CONFIG["host_os"].include? "darwin"
end