luffa 1.0.6 → 1.0.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 68615d981766a9547734862737395a68ac6d7c49
4
- data.tar.gz: b1f9eb0a801122f3a2f164b24b88018258519bc3
3
+ metadata.gz: 93d9621bd408e38894694a62ef51be69b8ea6a1e
4
+ data.tar.gz: e133693a756dc9f489b7b8178a8d3d27c97afa75
5
5
  SHA512:
6
- metadata.gz: 98fd49d02bd2e5f44f05aff150cb614f894cfcc82972c25c768b3d275ee7ac96c47a14027433f3c1867854144e6a6030be4dbc05e1049a4ad7f3a0f35d47c0bb
7
- data.tar.gz: 392b369b42d408bbabee85cfa6adf5988131c8b69735f2249a7ac2e9e96e98569458ba1d06f20af13b4a02e58c99208f31b119f9380499d1da32c0541a0e0e59
6
+ metadata.gz: 25e713220ee99cbf68382d53e511d1183a6a0d0c3dc077e94208b137467260c67c756199ac1cd50e98c9f78ae1a0ab40d4d212a28396d57c1ae99e417dad6688
7
+ data.tar.gz: 5eb34d2d9c71f63f666ee4dcac9fc215a26c26578b5c299d07d810a5560674976fc6b6410222dac180615f1813d090477b8789c80c7f8a346def6969a35b4628
@@ -13,12 +13,12 @@ module Luffa
13
13
  end
14
14
 
15
15
  def self.ideviceinstaller_available?
16
- path = bin_path
17
- path and File.exist? bin_path
16
+ path = self.bin_path
17
+ path and File.exist? self.bin_path
18
18
  end
19
19
 
20
20
  def self.idevice_id_available?
21
- path = idevice_id_bin_path
21
+ path = self.idevice_id_bin_path
22
22
  path and File.exist? path
23
23
  end
24
24
 
@@ -45,8 +45,8 @@ module Luffa
45
45
  # Also idevice_id, which ideviceinstaller relies on, will sometimes report
46
46
  # devices 2x which will cause ideviceinstaller to fail.
47
47
  devices = xcode_tools.instruments(:devices)
48
- if self.idevice_id_available?
49
- white_list = `#{idevice_id_bin_path} -l`.strip.split("\n")
48
+ if IDeviceInstaller.idevice_id_available?
49
+ white_list = `#{self.idevice_id_bin_path} -l`.strip.split("\n")
50
50
  devices.select do | device |
51
51
  white_list.include?(device.udid) && white_list.count(device.udid) == 1
52
52
  end
@@ -59,14 +59,14 @@ module Luffa
59
59
 
60
60
  DEFAULT_OPTIONS = { :timeout => 10.0, :tries => 2 }
61
61
 
62
- def bin_path
63
- @bin_path ||= `which ideviceinstaller`.chomp!
62
+ def self.bin_path
63
+ @@bin_path ||= `which ideviceinstaller`.chomp!
64
64
  end
65
65
 
66
66
  def run_command_with_args(args, options={})
67
67
  merged_options = DEFAULT_OPTIONS.merge(options)
68
68
 
69
- cmd = "#{bin_path} #{args.join(' ')}"
69
+ cmd = "#{IDeviceInstaller.bin_path} #{args.join(' ')}"
70
70
  Luffa.log_unix_cmd(cmd) if Luffa::Environment.debug?
71
71
 
72
72
  exit_status = nil
@@ -89,7 +89,7 @@ module Luffa
89
89
 
90
90
  Retriable.retriable({tries: tries, on: on, on_retry: on_retry} ) do
91
91
  Timeout.timeout(timeout, TimeoutError) do
92
- Open3.popen3(bin_path, *args) do |_, stdout, stderr, process_status|
92
+ Open3.popen3(IDeviceInstaller.bin_path, *args) do |_, stdout, stderr, process_status|
93
93
  err = stderr.read.strip
94
94
  if err && err != ''
95
95
  unless err[/iTunesMetadata.plist/,0] || err[/SC_Info/,0]
@@ -150,8 +150,8 @@ module Luffa
150
150
  true
151
151
  end
152
152
 
153
- def idevice_id_bin_path
154
- @idevice_id_bin_path ||= `which idevice_id`.chomp!
153
+ def self.idevice_id_bin_path
154
+ @@idevice_id_bin_path ||= `which idevice_id`.chomp!
155
155
  end
156
156
  end
157
157
  end
data/lib/luffa/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  module Luffa
2
- VERSION = '1.0.6'
2
+ VERSION = '1.0.7'
3
3
 
4
4
  # A model of a software release version that can be used to compare two versions.
5
5
  #
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: luffa
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.6
4
+ version: 1.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jonas Maturana Larsen