+ fi
+ # without --no-sandbox, it fails due to not having user namespaces
+ # enabled. As of 2026, User namespaces has too often been a
+ # mechanism for giving root rather than being useful as a security
+ # measure.
+ echo "iank: running CHROMIUM_FLAGS=--enable-remote-extensions $cmd -- --no-sandbox $*"
+ CHROMIUM_FLAGS=--enable-remote-extensions $cmd -- --no-sandbox "$@" &
+ pid=$!
+ # wait in case it dies right away so that we print the output instead of exiting
+ sleep 2
+ prtmp=$(jobs -s; jobs -r)
+ if (( ${#prtmp} != 0 )); then
+ printf '\n\n\n\n\n#################\n\n'
+ echo "iank: exiting this shell for convenience"
+ sleep 0.5
+ r
+ else
+ # background: The pid arg is required to get the exit code.
+ wait $pid || ret=$?
+ printf '\n\n\n\n\n#################\n\n'
+ echo "iank: detected chromium exit with success (perhaps it was already running). exiting this shell for convenience"
+ sleep 2
+ r