Fix sky_tool start/listen on iOS
This commit is contained in:
parent
82e8e3f079
commit
cb6b303996
@ -603,9 +603,8 @@ class IOSDevice(object):
|
|||||||
'1'
|
'1'
|
||||||
]
|
]
|
||||||
logging.info(' '.join(cmd))
|
logging.info(' '.join(cmd))
|
||||||
out = subprocess.check_output(cmd)
|
subprocess.check_output(cmd)
|
||||||
match = re.search(r'\[\.\.\.\.\] Found [^\)]*\) connected', out)
|
cls._is_connected = True
|
||||||
cls._is_connected = match is not None
|
|
||||||
except subprocess.CalledProcessError:
|
except subprocess.CalledProcessError:
|
||||||
cls._is_connected = False
|
cls._is_connected = False
|
||||||
return cls._is_connected
|
return cls._is_connected
|
||||||
@ -1030,15 +1029,17 @@ class StartListening(object):
|
|||||||
while True:
|
while True:
|
||||||
logging.info('Updating running Sky apps...')
|
logging.info('Updating running Sky apps...')
|
||||||
|
|
||||||
# Restart the app on Android. Android does not currently restart using skyx files.
|
device = AndroidDevice()
|
||||||
cmd = [
|
if device.is_connected():
|
||||||
sys.executable,
|
# Restart the app on Android. Android does not currently restart using skyx files.
|
||||||
os.path.abspath(__file__),
|
cmd = [
|
||||||
'start',
|
sys.executable,
|
||||||
'--poke'
|
os.path.abspath(__file__),
|
||||||
]
|
'start',
|
||||||
logging.info(' '.join(cmd))
|
'--poke'
|
||||||
subprocess.check_call(cmd)
|
]
|
||||||
|
logging.info(' '.join(cmd))
|
||||||
|
subprocess.check_call(cmd)
|
||||||
|
|
||||||
if args.local_build:
|
if args.local_build:
|
||||||
# Currently sending to iOS only works if you are building Sky locally
|
# Currently sending to iOS only works if you are building Sky locally
|
||||||
|
Loading…
x
Reference in New Issue
Block a user