osx zsh doesn't seem to have substr?