#!/usr/bin/env python3 """Parse a uiautomator dump into labelled, tappable nodes. Kept in its own file rather than inlined into the shell script: the first version was a python -c embedded in a bash case block, and the nested quoting silently mangled the regexes so the dump reported one element and a tap landed on the wrong one. Usage: uinodes.py list < dump.xml uinodes.py find