Add check for haslocaldir()
Work around zshenv dependent on $SHELL

References #94.