standardize leading/trailing whitespace of output