diff --git a/sh/.config/sh/env b/sh/.config/sh/env index 8e8a25f..db99a4e 100644 --- a/sh/.config/sh/env +++ b/sh/.config/sh/env @@ -6,9 +6,6 @@ # shellcheck source=xdg [ -f ~/.config/sh/xdg ] && . ~/.config/sh/xdg -# anything on BIN_HOME should be executable form anywhere -export PATH="$PATH:$XDG_BIN_HOME" - ############################### ## BEGIN GLOBAL ENV VARS ## ############################### diff --git a/sh/.config/sh/xdg b/sh/.config/sh/xdg index 470404a..8738649 100644 --- a/sh/.config/sh/xdg +++ b/sh/.config/sh/xdg @@ -31,8 +31,10 @@ export XDG_VIDEOS_DIR="$HOME/videos" ## Non-Standard additions # non-standard, is added to path to enable execution of any files herein -test "$XDG_BIN_HOME" || export XDG_BIN_HOME="$HOME/.local/bin" test "$XDG_PROJECTS_DIR" || export XDG_PROJECTS_DIR="$HOME/projects" +test "$XDG_BIN_HOME" || export XDG_BIN_HOME="$HOME/.local/bin" +# anything on BIN_HOME should be executable form anywhere +export PATH="$PATH:$XDG_BIN_HOME" xdg_isThere() { if [ -e "$1" ] || [ -h "$1" ]; then @@ -65,8 +67,31 @@ xdg_isThere "$XDG_PROJECTS_DIR" || xdg_makeForUser "$XDG_PROJECTS_DIR" unset -f xdg_isThere xdg_makeForUser ## Applications that can be set through environment variables -export NVM_DIR="$XDG_DATA_HOME/nvm" -export TMUX_PLUGIN_MANAGER_PATH="$XDG_DATA_HOME/tmux" -export ZDOTDIR="$XDG_CONFIG_HOME/zsh" export ANDROID_HOME="$XDG_DATA_HOME/android" export ATOM_HOME="$XDG_DATA_HOME/atom" +export CARGO_HOME="$XDG_DATA_HOME/cargo" +export DOCKER_CONFIG="$XDG_CONFIG_HOME/docker" +export GEM_HOME="$XDG_DATA_HOME/gem" +export GEM_SPEC_CACHE="$XDG_CACHE_HOME/gem" +export GNUPGHOME="$XDG_DATA_HOME/gnupg" +export GRADLE_USER_HOME="$XDG_DATA_HOME/gradle" +export GRIPHOME="$XDG_CONFIG_HOME/grip" +export IMAPFILTER_HOME="$XDG_CONFIG_HOME/imapfilter" +export IPYTHONDIR="$XDG_CONFIG_HOME/ipython" +export KDEHOME="$XDG_CONFIG_HOME/kde" +export KODI_DATA="$XDG_DATA_HOME/kodi" +export LESSHISTFILE="XDG_STATE_HOME/lesshst" +export MPLAYER_HOME="$XDG_CONFIG_HOME/mplayer" +export NODE_REPL_HISTORY="$XDG_STATE_HOME/node_repl_history" +export NVM_DIR="$XDG_DATA_HOME/nvm" +export PYTHONSTARTUP="$XDG_CONFIG_HOME/python/pythonrc" +export SQLITE_HISTORY="$XDG_STATE_HOME/sqlite_history" +export TEXMFVAR="$XDG_CACHE_HOME/texlive/texmf-var" +export TMUX_PLUGIN_MANAGER_PATH="$XDG_DATA_HOME/tmux" +export VAGRANT_HOME="$XDG_DATA_HOME/vagrant" +export WINEPREFIX="$XDG_DATA_HOME/wine" +export ZDOTDIR="$XDG_CONFIG_HOME/zsh" +export _JAVA_OPTIONS=-Djava.util.prefs.userRoot="$XDG_CONFIG_HOME"/java + +alias yarn='yarn --use-yarnrc "$XDG_CONFIG_HOME/yarn/config"' +alias wget='wget --hsts-file="$XDG_STATE_HOME/wget-hsts"' diff --git a/zsh/.zshenv b/zsh/.zshenv index 0f2caf2..dd930d3 100644 --- a/zsh/.zshenv +++ b/zsh/.zshenv @@ -3,4 +3,4 @@ # make zsh source the correct directory export XDG_CONFIG_HOME=${XDG_CONFIG_HOME:-"$HOME/.config"} -ZDOTDIR="$XDG_CONFIG_HOME/zsh" +ZDOTDIR="${XDG_CONFIG_HOME:-"$HOME/.config"}/zsh"