work in progress env.sh, callable through 'txc' - really need to fix idempotency