refine the cmd layout