Formats commands.