fix some prompt bugs with empty or new repos