sort commands and fix typos