]> git.donarmstrong.com Git - zsh.git/blob - .zsh/zshrc/00_varsetup
add zsh modes to everything
[zsh.git] / .zsh / zshrc / 00_varsetup
1 # -*- mode: sh -*-
2 # zshrc/00_varsetup
3 #
4 # set up global variables used by the shell
5 #
6 # Copyright © 1994–2008 martin f. krafft <madduck@madduck.net>
7 # Released under the terms of the Artistic Licence 2.0
8 #
9 # Source repository: git://git.madduck.net/etc/zsh.git
10 #
11
12 # automatically remove duplicates from these arrays
13 typeset -gU path cdpath fpath manpath fignore
14
15 # http://xanana.ucsc.edu/~wgscott/wordpress_new/wordpress/?p=12
16 typeset -ga preexec_functions
17 typeset -ga precmd_functions
18 typeset -ga chpwd_functions
19
20 __chpwd_run_first()
21 {
22   [[ -n $__CHPWD_RUN_FIRST ]] || return
23   eval "$__CHPWD_RUN_FIRST"
24 }
25 chpwd_functions+=__chpwd_run_first
26
27 # warn on accidental creation of global variables
28 # unset for now until we work out the corner cases, like warning about $reply
29 # and $HISTFILE or $REPORTTIME.
30 #setopt warn_create_global
31
32 # vim:ft=zsh