Sha256: b837b9c1207ec78b03a76bc7ba79401fb98bd67c2913c7aee02e9ba1876c4d83
Contents?: true
Size: 880 Bytes
Versions: 1
Compression:
Stored size: 880 Bytes
Contents
require 'skippy/os/common' require 'skippy/sketchup/app' class Skippy::OSMac < Skippy::OSCommon # @param [String] executable_path def launch_app(executable_path, *args) command = %(open -a "#{executable_path}") unless args.empty? command << " --args #{args.join(' ')}" end execute_command(command) end def sketchup_apps apps = [] pattern = '/Applications/SketchUp */' Dir.glob(pattern) { |path| app = File.join(path, 'SketchUp.app') debug_lib = File.join(app, 'Contents/Frameworks/SURubyDebugger.dylib') version = File.basename(path).match(/[0-9.]+$/)[0].to_i apps << Skippy::SketchUpApp.from_hash( executable: app, version: version, can_debug: File.exist?(debug_lib), is64bit: version > 2015, ) } apps.sort_by(&:version) end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
skippy-0.4.0.a | lib/skippy/os/mac.rb |