typeset -ga precmd_functions
typeset -ga chpwd_functions
+__chpwd_run_first()
+{
+ [[ -n $__CHPWD_RUN_FIRST ]] || return
+ eval "$__CHPWD_RUN_FIRST"
+}
+chpwd_functions+=__chpwd_run_first
+
# warn on accidental creation of global variables
# unset for now until we work out the corner cases, like warning about $reply
# and $HISTFILE or $REPORTTIME.