taking care of newline in command results