Class: FluentCommandBuilder::OsxVersionDetector
- Inherits:
-
Object
- Object
- FluentCommandBuilder::OsxVersionDetector
- Defined in:
- lib/fluent_command_builder/version_detectors/osx_version_detector.rb
Instance Attribute Summary collapse
-
#backticks_executor ⇒ Object
Returns the value of attribute backticks_executor.
Instance Method Summary collapse
-
#initialize ⇒ OsxVersionDetector
constructor
A new instance of OsxVersionDetector.
- #version(path = nil) ⇒ Object
Constructor Details
#initialize ⇒ OsxVersionDetector
Returns a new instance of OsxVersionDetector.
8 9 10 |
# File 'lib/fluent_command_builder/version_detectors/osx_version_detector.rb', line 8 def initialize @backticks_executor = BackticksExecutor.new end |
Instance Attribute Details
#backticks_executor ⇒ Object
Returns the value of attribute backticks_executor.
6 7 8 |
# File 'lib/fluent_command_builder/version_detectors/osx_version_detector.rb', line 6 def backticks_executor @backticks_executor end |
Instance Method Details
#version(path = nil) ⇒ Object
12 13 14 15 16 |
# File 'lib/fluent_command_builder/version_detectors/osx_version_detector.rb', line 12 def version(path=nil) d = StandardVersionDetector.new 'sw_vers', '-productVersion' d.backticks_executor = @backticks_executor d.version end |