wd.sh: switch test to '-e'

Darwin (BSD) does not have '-a' option for test; using '-e' instead.
wd.sh: remove errant 'f' from sed command