some fixes for cli