Sha256: c7f60486c65b2a50178e4c19ca5de54a6871d2201c1625690e64e0af531b23d6

Contents?: true

Size: 656 Bytes

Versions: 7

Compression:

Stored size: 656 Bytes

Contents

module SimCtl
  class DevicePath
    attr_reader :device_plist, :global_preferences_plist, :home, :preferences_plist

    def initialize(udid)
      @home = File.join(device_set_path, udid)
      @device_plist = File.join(@home, 'device.plist')
      @global_preferences_plist = File.join(@home, 'data/Library/Preferences/.GlobalPreferences.plist')
      @preferences_plist = File.join(@home, 'data/Library/Preferences/com.apple.Preferences.plist')
    end

    private

    def device_set_path
      return SimCtl.device_set_path unless SimCtl.device_set_path.nil?
      File.join(ENV['HOME'], 'Library/Developer/CoreSimulator/Devices')
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
simctl-1.5.8 lib/simctl/device_path.rb
simctl-1.5.7 lib/simctl/device_path.rb
simctl-1.5.6 lib/simctl/device_path.rb
simctl-1.5.5 lib/simctl/device_path.rb
simctl-1.5.4 lib/simctl/device_path.rb
simctl-1.5.3 lib/simctl/device_path.rb
simctl-1.5.2 lib/simctl/device_path.rb