X-Git-Url: https://git.sev.monster/~sev/dotfiles.git/blobdiff_plain/3cec048120c6d59a3f8916078f8f6a99d3e70025..4be2bcd2e2f69ffa226d75f6e06ca2280a164cee:/base/.zshenv diff --git a/base/.zshenv b/base/.zshenv index 7e0680c..1f3e198 100644 --- a/base/.zshenv +++ b/base/.zshenv @@ -37,19 +37,21 @@ if [[ -v _sev_reset_shell || $SHLVL == 1 ]] { export XDG_DATA_DIRS=~/.local/share:/usr/pkg/share:/usr/local/share:/usr/share export XDG_CACHE_HOME=~/tmp export XDG_RUNTIME_DIR=~/tmp + if [[ -e $XDG_CONFIG_HOME/user-dirs.dirs ]] { + source $XDG_CONFIG_HOME/user-dirs.dirs + } ## create tmp link t=${TMPDIR:-/tmp}/home-$LOGNAME - h=$HOME/tmp if [[ ! -e $t ]] { mkdir -m 700 $t >/dev/null 2>&1 # TODO: check if dir exists after mkdir } # allow opaque entries to override link creation - if [[ ! -e $h ]] { - ln -sf $t $h >/dev/null 2>&1 + if [[ ! -e $XDG_RUNTIME_DIR ]] { + ln -sf $t $XDG_RUNTIME_DIR >/dev/null 2>&1 } - unset t h + unset t ## ssh agents # NOTE: preferred order of agents to check: okcagent, gnupg, openssh