Actually create XDG_RUNTIME_DIR when the variable is set in zshenv

This commit is contained in:
Danielle McLean 2016-10-22 21:12:09 +11:00
parent 5ce16ad385
commit ea4bacbb57
No known key found for this signature in database
GPG key ID: CC91589719027E94

1
zshenv
View file

@ -8,6 +8,7 @@
# /xdg-$USER is that TMPDIR does not necessarily belong to the current user # /xdg-$USER is that TMPDIR does not necessarily belong to the current user
# exclusively (although it does under MacOS and PAM). # exclusively (although it does under MacOS and PAM).
[[ -z $XDG_RUNTIME_DIR ]] && XDG_RUNTIME_DIR=${TMPDIR%/}/xdg-$USER [[ -z $XDG_RUNTIME_DIR ]] && XDG_RUNTIME_DIR=${TMPDIR%/}/xdg-$USER
[[ -d $XDG_RUNTIME_DIR ]] || mkdir -p $XDG_RUNTIME_DIR
export XDG_CONFIG_HOME XDG_CACHE_HOME XDG_DATA_HOME XDG_RUNTIME_DIR export XDG_CONFIG_HOME XDG_CACHE_HOME XDG_DATA_HOME XDG_RUNTIME_DIR
# The real zsh config lives in XDG_CONFIG_HOME! ;) # The real zsh config lives in XDG_CONFIG_HOME! ;)