tg.sh: support tg status --exit-code