X-Git-Url: https://iankelling.org/git/?a=blobdiff_plain;f=filesystem%2Fetc%2Fprofile.d%2Fenvironment.sh;h=96f0271c18aadc5a34f63460aab960f0d870948a;hb=e03e99848bc5fbc7ad527513e0aa4b0fc9c4d6fb;hp=4c5794f4fc918219cc18131e9e5e22f3f0f14f0e;hpb=b5152768e90016afe8ff2d55cc9f38d08396b0fc;p=distro-setup diff --git a/filesystem/etc/profile.d/environment.sh b/filesystem/etc/profile.d/environment.sh index 4c5794f..96f0271 100644 --- a/filesystem/etc/profile.d/environment.sh +++ b/filesystem/etc/profile.d/environment.sh @@ -1,19 +1,29 @@ -if [ -f $HOME/path_add-function ]; then - . $HOME/path_add-function - path_add /usr/sbin /usr/local/sbin /sbin - path_add /a/exe /a/opt/bin $HOME/.cabal/bin +if [ -f $HOME/path-add-function ]; then + . $HOME/path-add-function + path-add /usr/sbin /usr/local/sbin /sbin /a/exe /a/opt/bin + path-add --end $HOME/.cabal/bin + + if [ -r /etc/alternatives/java_sdk ]; then + export JAVA_HOME=/etc/alternatives/java_sdk + path-add /etc/alternatives/java_sdk + fi + + export GUIX_PROFILE=/root/.config/guix/current + if [[ -e $GUIX_PROFILE/etc/profile ]]; then + source $GUIX_PROFILE/etc/profile + fi + path-add $HOME/.guix-profile/bin + export GUIX_LOCPATH=$HOME/.guix-profile/lib/locale - if [ -r /etc/alternatives/java_sdk ]; then - export JAVA_HOME=/etc/alternatives/java_sdk - path_add /etc/alternatives/java_sdk - fi fi + export EDITOR="emacsclient" # this makes emacsclient file/-c start a server instance if none is running, # instead of some alternate editor logic export ALTERNATE_EDITOR="" +export PITHOSFLY_SAVE_DIR=/a/pandora_rips4 # makes subsequent syscalls to localtime use cached timezone, # so basically restart the comp if you change time zones, @@ -39,26 +49,29 @@ export TZ=:/etc/localtime # I also added the bit about xmessaging the stderr, # because I'd like to know if the command fails if [ -f /etc/fedora-release ]; then - : ${GNUPGHOME=$HOME/.gnupg} + : ${GNUPGHOME=$HOME/.gnupg} - GPGAGENT=/usr/bin/gpg-agent - PID_FILE="$GNUPGHOME/gpg-agent-info-$(hostname)" + GPGAGENT=/usr/bin/gpg-agent + PID_FILE="$GNUPGHOME/gpg-agent-info-$(hostname)" - if ! $GPGAGENT 2>/dev/null; then - temp="$(mktemp)" - eval "$($GPGAGENT --homedir /p/do-not-delete --daemon --sh --write-env-file=$PID_FILE 2>$temp)" - temperr="$(<"$temp")" - [ -n "$temperr" ] && xmessage "gpg-agent stderr: $temperr" - elif [ -r "$PID_FILE" ]; then - . "$PID_FILE" - export GPG_AGENT_INFO - fi + if ! $GPGAGENT 2>/dev/null; then + temp="$(mktemp)" + eval "$($GPGAGENT --homedir /p/do-not-delete --daemon --sh --write-env-file=$PID_FILE 2>$temp)" + temperr="$(<"$temp")" + [ -n "$temperr" ] && xmessage "gpg-agent stderr: $temperr" + elif [ -r "$PID_FILE" ]; then + . "$PID_FILE" + export GPG_AGENT_INFO + fi fi # background: # ubuntu has 002 for non-system users, debian has 022. 002 makes groups # be rw instead of r. # +# I think the actual setting is somewhere in the pam settings, I haven't +# bothered to figure that out. +# # ubuntu is more user friendly when using multiple users. However, # it also makes it so if you create a file as a regular user then move # it to become a system file, it's got slightly wrong permissions, and