From 3b177d8c95f70db8e27fd046711f480e81ea3fa7 Mon Sep 17 00:00:00 2001
From: Case Duckworth
Date: Sun, 16 Apr 2023 17:06:22 -0500
Subject: uhhhh

---
 profile/01_path.sh |  2 +-
 profile/manpath.sh |  4 ++--
 profile/nodejs.sh  |  2 +-
 profile/profile    |  5 ++++-
 profile/python.sh  |  5 ++++-
 profile/xdg.sh     | 55 ++++++++++++++++++++++++++++++++++++++++++++++--------
 6 files changed, 59 insertions(+), 14 deletions(-)

(limited to 'profile')

diff --git a/profile/01_path.sh b/profile/01_path.sh
index 6675241..8b18f5e 100644
--- a/profile/01_path.sh
+++ b/profile/01_path.sh
@@ -1,6 +1,6 @@
 # PATH and variables for $HOME-local installations
 
-LOCAL_PREFIX="$LOCAL_PATH"
+LOCAL_PREFIX="$HOME/usr"
 export LOCAL_PREFIX
 
 # Pkg-config
diff --git a/profile/manpath.sh b/profile/manpath.sh
index b52f5f8..bda4fd2 100644
--- a/profile/manpath.sh
+++ b/profile/manpath.sh
@@ -3,8 +3,8 @@
 path_add_unsafe MANPATH \
 	"${XDG_DATA_HOME:-$LOCAL_PREFIX/share}/man" \
 	"$LOCAL_PREFIX/local/man" \
-	"$LOCAL_PATH/local/man" \
-	"$LOCAL_PATH/man"
+	"$LOCAL_PREFIX/local/man" \
+	"$LOCAL_PREFIX/man"
 
 # $MANPATH ends with `:' so that manpath(1) will prepend it to its
 # special thing.
diff --git a/profile/nodejs.sh b/profile/nodejs.sh
index 6d95dea..224dbbe 100644
--- a/profile/nodejs.sh
+++ b/profile/nodejs.sh
@@ -1,3 +1,3 @@
 # node.js environment
 
-export npm_config_prefix="$LOCAL_PATH"
+export npm_config_prefix="$LOCAL_PREFIX"
diff --git a/profile/profile b/profile/profile
index 9a81186..5faff51 100644
--- a/profile/profile
+++ b/profile/profile
@@ -4,10 +4,13 @@
 # Source system profile
 source /etc/profile
 
+# Local prefix
+export LOCAL_PREFIX="$HOME/usr"
+
 # XDG directories
 export XDG_CONFIG_HOME="$HOME/etc"
 export XDG_CACHE_HOME="$HOME/var/cache"
-export XDG_DATA_HOME="$LOCAL_PATH/share"
+export XDG_DATA_HOME="$LOCAL_PREFIX/share"
 
 export XDG_DATA_DIRS="${XDG_DATA_DIRS:-/usr/local/share:/usr/share}"
 export XDG_CONFIG_DIRS="${XDG_CONFIG_DIRS:-/etc/xdg}"
diff --git a/profile/python.sh b/profile/python.sh
index 80d4ee2..9353cfe 100644
--- a/profile/python.sh
+++ b/profile/python.sh
@@ -3,4 +3,7 @@
 # sometimes it's unavoidable.
 
 # from grym on #emacs --- TODO: research what this actually does, lol
-export PIP_REQUIRE_VIRTUALENV=1
+# it's annoying ... (2023-02-08)
+#export PIP_REQUIRE_VIRTUALENV=1
+
+path_add_to_PATH "$XDG_DATA_HOME/python/bin"
diff --git a/profile/xdg.sh b/profile/xdg.sh
index e11c5df..a4e395f 100644
--- a/profile/xdg.sh
+++ b/profile/xdg.sh
@@ -4,15 +4,17 @@
 # moved there (e.g., HISTFILE is in history.bash).  So variables might
 # move /out/ of this directory, but they probably won't move /in/.
 
-# See also [[https://github.com/b3nj5m1n/xdg-ninja][xdg-ninja]].
+# See also https://github.com/b3nj5m1n/xdg-ninja,
+# https://wiki.archlinux.org/title/XDG_Base_Directory#Support
 
 # Readline
-export INPUTRC="$XDG_CONFIG_HOME"/readline/inputrc
+export INPUTRC="$XDG_CONFIG_HOME/readline/inputrc"
+export RLWRAP_HOME="$XDG_DATA_HOME/rlwrap"
 
 # Less
-export LESSKEY="$XDG_CONFIG_HOME"/less/lesskey
-export LESSHISTFILE="$XDG_CACHE_HOME"/less/history
-mkdir -p "$XDG_CACHE_HOME"/less
+export LESSKEY="$XDG_CONFIG_HOME/less/lesskey"
+export LESSHISTFILE="$XDG_CACHE_HOME/less/history"
+mkdir -p "$XDG_CACHE_HOME/less"
 
 # Vim
 export VIMINIT="source ${XDG_CONFIG_HOME:=$HOME/.config}/vim/vimrc"
@@ -27,9 +29,14 @@ export LYNX_CFG="$XDG_CONFIG_HOME/lynx/lynx.cfg"
 export XDG_RUNTIME_DIR="${XDG_RUNTIME_DIR:-$HOME}"
 export XINITRC="$XDG_CONFIG_HOME/X11/xinitrc"
 export XSERVERRC="$XDG_CONFIG_HOME/X11/xserverrc"
+export USERXSESSION="$XDG_CACHE_HOME/X11/xsession"
+export ALTUSERXSESSION="$XDG_CACHE_HOME/X11/Xsession"
+export ERRFILE="$XDG_CACHE_HOME/X11/xsession-errors"
 
-# Notmuch
-export NOTMUCH_CONFIG="${XDG_CONFIG_HOME:=$HOME/.config}/notmuch/config"
+
+
+# Notmuch -- https://notmuchmail.org/pipermail/notmuch/2011/007007.html
+export NOTMUCH_CONFIG="${XDG_CONFIG_HOME:=$HOME/.config}/notmuch/default/config"
 
 # GNUPG
 export GNUPGHOME="$XDG_DATA_HOME/gnupg"
@@ -39,7 +46,39 @@ export ICEAUTHORITY="$XDG_CACHE_HOME/ICEauthority"
 
 # mbsync (requires alias)
 export MBSYNC_CONFIG_HOME="$XDG_CONFIG_HOME/isync/mbsyncrc"
-alias mbsync='mbsync -c "$MBSYNC_CONFIG_HOME"'
+alias mbsync='command mbsync -c "$MBSYNC_CONFIG_HOME"'
 
 # npm
 export NPM_CONFIG_USERCONFIG="$XDG_CONFIG_HOME/npm/npmrc"
+
+# bash-complete
+export BASH_COMPLETION_USER_FILE="$XDG_CONFIG_HOME/bash/completion"
+
+# aspell
+ASPELL_CONF="per-conf $XDG_CONFIG_HOME/aspell/aspell.conf"
+ASPELL_CONF="$ASPELL_CONF; personal $XDG_CONFIG_HOME/aspell/en.pws"
+ASPELL_CONF="$ASPELL_CONF; repl $XDG_CONFIG_HOME/aspell/en.prepl"
+mkdir -p "$XDG_CONFIG_HOME/aspell"
+export ASPELL_CONF
+
+# Xcompose
+export XCOMPOSEFILE="$XDG_CONFIG_HOME/xorg/xcompose"
+export XCOMPOSECACHE="$XDG_CACHE_HOME/xorg/xcompose"
+
+# sqlite
+export SQLITE_HISTORY="$XDG_DATA_HOME/sqlite_history"
+alias sqlite3='sqlite3 -init "$XDG_CONFIG_HOME/sqlite3/sqliterc"'
+
+# python
+export PYTHONSTARTUPFILE="$XDG_CONFIG_HOME/python/startup"
+export PYTHONPYCACHEPREFIX="$XDG_CACHE_HOME/python"
+export PYTHON_EGG_CACHE="$XDG_CACHE_HOME/python/eggs"
+export PYTHONUSERBASE="$XDG_DATA_HOME/python"
+
+# wget
+export WGETRC="$XDG_CONFIG_HOME/wget/config"
+mkdir -p "$XDG_CONFIG_HOME/wget"
+alias wget='wget --hsts-file="$XDG_CACHE_HOME/wget-hsts"'
+
+# dvdcss
+export DVDCSS_HOME="$XDG_CACHE_HOME/dvdcss"
-- 
cgit 1.4.1-21-gabe81