checking output of commands