pymobiledevice3
pymobiledevice3 copied to clipboard
How to exit pymobiledevice3 syslog live from shell script
I've run pymobiledevice3 syslog live
to receive livetime iPhone log. I can exit use control
+c
shortcut, but how can I exit from shell script?
Use your own python code to make such a snippet:
from pymobiledevice3.lockdown import LockdownClient
from pymobiledevice3.services.os_trace import OsTraceService
with OsTraceService(LockdownClient()) as os_trace:
for line in os_trace.syslog():
print(line)
if some_condition_reached:
break