Per directory history for zsh which falls back to a global history if the per directory history fails