Stack Overflow archive
4 scoreaccepted

ADB shell command to execute repeatedly every x interval

score
4
question views
3.5K
license
CC BY-SA 3.0

You can use an unconditional loop:

java
while true; do ls -l; sleep 20; done

You can also look into tools like inotifywait or fsmon depending on what you are trying to accomplish. You can also install busybox for Android which contains the watch command.

Originally posted on Stack Overflow. Public user contributions are licensed under Creative Commons Attribution-ShareAlike.