you can do a rm -d on ./tmp which will only remove it if it is empty