lib/dryrun/dryrun_utils.rb in dryrun-0.8.1 vs lib/dryrun/dryrun_utils.rb in dryrun-0.9.0
- old
+ new
@@ -44,17 +44,21 @@
adb_arg = " -s #{$device.name} " unless $device.nil?
path = "#{$sdk} #{adb_arg} #{args} "
run(path)
end
+ def self.is_folder? (path)
+ File.directory?(path)
+ end
+
def self.run(path)
Open3.popen3(path) do |_stdin, stdout, _stderr|
devices = []
stdout.each do |line|
line = line.strip
if !line.empty? && line !~ /^List of devices/ && !line.start_with?('adb') && !line.start_with?('*')
parts = line.split
- devices << AdbDevice::Device.new(parts[0], parts[1])
+ devices << Dryrun::Device.new(parts[0], parts[1])
end
end
devices
end
end