Fixed sed -i issue for OSX vs Linux