#!/bin/bash while ! [ -e /dev/dri/card0 ]; do sleep 0.2; done exec "$@"