fix publish script for OS X