Modify sed command to work on OSX