Sha256: 790570b3a2a92f38f2ea00f7273d35c31201fc97a632b80187becb856e01770c
Contents?: true
Size: 1.02 KB
Versions: 16
Compression:
Stored size: 1.02 KB
Contents
module Fission class Config attr_accessor :attributes CONF_FILE = File.expand_path '~/.fissionrc' def initialize @attributes = {} load_from_file if @attributes['vm_dir'].blank? @attributes['vm_dir'] = File.expand_path('~/Documents/Virtual Machines.localized/') end if File.exists?('/Library/Application Support/VMware Fusion/vmrun') @attributes['vmrun_bin'] = '/Library/Application Support/VMware Fusion/vmrun' else @attributes['vmrun_bin'] = '/Applications/VMware Fusion.app/Contents/Library/vmrun' end @attributes['vmrun_cmd'] = "#{@attributes['vmrun_bin'].gsub(' ', '\ ')} -T fusion" @attributes['plist_file'] = File.expand_path('~/Library/Preferences/com.vmware.fusion.plist') @attributes['gui_bin'] = File.expand_path('/Applications/VMware Fusion.app/Contents/MacOS/vmware') end private def load_from_file if File.file?(CONF_FILE) @attributes.merge!(YAML.load_file(CONF_FILE)) end end end end
Version data entries
16 entries across 16 versions & 1 rubygems