Top Level Namespace
Defined Under Namespace
Modules: WhichOsx Classes: WhichOSX
Constant Summary collapse
- VERSION =
output
Instance Method Summary collapse
-
#output ⇒ Object
Regex for “##.#.#”.
Instance Method Details
#output ⇒ Object
Regex for “##.#.#”
4 5 6 7 8 |
# File 'lib/which_osx.rb', line 4 def output `sw_vers`.scan(/\d\d\.\d(?:.\d)?/).first rescue Errno::ENOENT => e puts "This computer is not running Mac OS X. This gem won't work! Sorry :(" end |