Commit d36af446 authored by Nathan Kerr's avatar Nathan Kerr

Change Regex to correctly match against my device.

Since we don't care about the port, just allow any characters between the spaces after the device ID and the product.

Running Windows 10, running "adb devices -l" with my device attached to the computer gives:
FA34MW904146           device product:cm_m7 model:One device:m7

Which wasn't being matched correctly (no info on USB port).
parent ed297f47
......@@ -509,7 +509,7 @@ class AndroidDevice extends Device {
// 015d172c98400a03 device usb:340787200X product:nakasi model:Nexus_7 device:grouper
RegExp deviceRegex1 = new RegExp(
r'^(\S+)\s+device\s+\S+\s+product:(\S+)\s+model:(\S+)\s+device:(\S+)$');
r'^(\S+)\s+device\s+.*product:(\S+)\s+model:(\S+)\s+device:(\S+)$');
// 0149947A0D01500C device usb:340787200X
RegExp deviceRegex2 = new RegExp(r'^(\S+)\s+device\s+\S+$');
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment