fix for sed and newline for osx