Changes to zsh functions from holman's upstream.