-
Notifications
You must be signed in to change notification settings - Fork 2
/
zshenv
31 lines (26 loc) · 956 Bytes
/
zshenv
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# DOCS: This is read first and read every time, regardless of the shell being
# login, interactive, or none. This is the recommended place to set environment
# variables needed on every shell, even the ones launching scripts
#
# NOTE: Why would you need this? Because, for example, if you have a script that
# gets called by launchd, it will run under non-interactive non-login shell, so
# neither .zshrc nor .zprofile will get loaded.
#
# .zshenv → .zprofile → .zshrc → .zlogin → .zlogout
export BROWSER=firefox
export VISUAL=nvim
export EDITOR=nvim
export GOROOT=$HOME/.go
export MANPAGER="sh -c 'col -bx | bat -l man -p --theme=\"default\"'"
export MANROFFOPT="-c"
typeset -U path
# Set $PATH if ~/.local/bin exist
if [ -d "$HOME/.local/bin" ]; then
path=($HOME/.local/bin $path)
fi
# Load cargo env if it exists
if [ -d "$HOME/.cargo" ]; then
. "$HOME/.cargo/env"
fi
# Local config
[[ -f ~/.zshenv.local ]] && source ~/.zshenv.local