]>
Commit | Line | Data |
---|---|---|
1 | ### load site-specific | |
2 | [[ -f ~/.zshenv.local ]] && source ~/.zshenv.local | |
3 | ||
4 | ### fix broken term | |
5 | if (( $#terminfo == 0 )) { | |
6 | [[ -o interactive ]] && | |
7 | print -P "%F{red}!!! Can't find terminfo for $TERM, using xterm%f" | |
8 | TERM=xterm | |
9 | } | |
10 | ||
11 | ### early zprofile sourcing | |
12 | # NOTE: see comments in .zprofile for additional rationale for this | |
13 | if [[ ! -o login ]] { | |
14 | if [[ -v _sev_olduser && $_sev_olduser != $USERNAME ]] { | |
15 | # set up some user-dependent stuff since we switched users | |
16 | # XXX: _sev_switched_users is no longer implemented | |
17 | _sev_switched_users= source ${ZDOTDIR:-~}/.zprofile | |
18 | } elif [[ $SHLVL == 1 ]] { | |
19 | # ensure profile is loaded for toplevel shells; should hopefully be 1 | |
20 | # under Xorg or cron, which is where this would be most useful | |
21 | source ${ZDOTDIR:-~}/.zprofile | |
22 | } | |
23 | } else { | |
24 | # for convenience | |
25 | cd ~ | |
26 | } | |
27 | export _sev_olduser=$USERNAME | |
28 | ||
29 | # vim: et sts=4 sw=4 ts=8 tw=79 |