diff options
author | Alen <alen@dotfiles.xyz> | 2023-09-23 22:16:43 +0400 |
---|---|---|
committer | Alen <alen@dotfiles.xyz> | 2023-09-23 22:16:43 +0400 |
commit | 74fac2fd26ce672d02f68ef683463e9a86341aec (patch) | |
tree | 8b2a47bd71dc81e58a01a3d4004148a07507ada9 /dot_zshenv | |
parent | 6cf9a6f786d7b6037efef0e611d36b3824d3a775 (diff) |
Add XDH_* env vars to zshenv
Diffstat (limited to 'dot_zshenv')
-rw-r--r-- | dot_zshenv | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/dot_zshenv b/dot_zshenv index 702bfd3..dff58be 100644 --- a/dot_zshenv +++ b/dot_zshenv @@ -25,6 +25,17 @@ setopt pushd_to_home # No arguments is the same as pushd $HOME - mimic setopt pushd_ignore_dups # Ignore pushd dupes export DIRSTACKSIZE=16 +# Set XDG_* path vars for better compat +# https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html +# TODO: XDG_RUNTIME_DIR cleanup on logout +[[ -v XDG_CONFIG_HONE ]] || export XDG_CONFIG_HOME=${HOME}/.config +[[ -v XDG_CACHE_HOME ]] || export XDG_CACHE_HOME=${HOME}/.cache +[[ -v XDG_DATA_HOME ]] || export XDG_DATA_HOME=${HOME}/.local/share +[[ -v XDG_STATE_HOME ]] || export XDG_STATE_HOME=${HOME}/.local/state +[[ -v XDG_DATA_DIRS ]] || export XDG_DATA_DIRS=/usr/local/share:/usr/share +[[ -v XDG_CONFIG_DIRS ]] || export XDG_CONFIG_DIRS=/etc/xdg +[[ -v XDG_RUNTIME_DIR ]] || export XDG_RUNTIME_DIR=${HOME}/.cache/xdg-runtime-dir + # (Re)set locales, a reminder that we live in a world built upon bad decisions export LANG=en_US.UTF-8 export LC_ALL=en_US.UTF-8 |