Clean up shell config.

This commit is contained in:
Gabriel Ebner 2024-08-10 10:07:28 -07:00
parent d7419fee10
commit 4a9084c186
2 changed files with 3 additions and 23 deletions

@ -16,10 +16,3 @@ if type -t nvim >/dev/null; then
fi fi
export BROWSER=xdg-open export BROWSER=xdg-open
alias udetokei='tokei $(rg --files)'
# passc
passc() {
pass show "$1" | (read i; cat; echo -n "$i" | xclip -l 1 -se c)
}

@ -4,8 +4,8 @@
# $MYPREFIX {{{1 # $MYPREFIX {{{1
add_to() { add_to() {
if [ -n "`eval echo \$\{$1\}`" ]; then if [ -n "${!1}" ]; then
export $1="$2:`eval echo \$\{$1\}`" export $1="$2:${!1}"
else else
export $1="$2" export $1="$2"
fi fi
@ -15,13 +15,12 @@ add_myprefix_to() {
add_to "$1" "$MYPREFIX/$2" add_to "$1" "$MYPREFIX/$2"
} }
export MYPREFIX=$HOME/.local MYPREFIX=$HOME/.local
add_to PATH ~/.cabal/bin add_to PATH ~/.cabal/bin
add_myprefix_to LD_LIBRARY_PATH lib add_myprefix_to LD_LIBRARY_PATH lib
add_to MANPATH :
add_myprefix_to MANPATH share/man add_myprefix_to MANPATH share/man
add_myprefix_to PKG_CONFIG_PATH lib/pkgconfig add_myprefix_to PKG_CONFIG_PATH lib/pkgconfig
@ -29,20 +28,8 @@ add_myprefix_to PKG_CONFIG_PATH lib/pkgconfig
add_myprefix_to PATH bin add_myprefix_to PATH bin
add_myprefix_to PATH sbin add_myprefix_to PATH sbin
if [ -x /usr/bin/perl ]; then
PERLVERSION="`perl -e 'printf"%vd\n",$^V'`"
add_myprefix_to PERL5LIB lib/perl/$PERLVERSION
add_myprefix_to PERL5LIB share/perl/$PERLVERSION
fi
add_myprefix_to R_LIBS lib/R:/usr/lib/R/site-library
if [ -d ~/build/android-sdk-linux ]; then if [ -d ~/build/android-sdk-linux ]; then
export ANDROID_HOME=$HOME/build/android-sdk-linux export ANDROID_HOME=$HOME/build/android-sdk-linux
add_to PATH $ANDROID_HOME/platform-tools:$ANDROID_HOME/tools add_to PATH $ANDROID_HOME/platform-tools:$ANDROID_HOME/tools
export ANDROID_SDK=$ANDROID_HOME ANDROID_NDK=$HOME/build/android-ndk-r9c export ANDROID_SDK=$ANDROID_HOME ANDROID_NDK=$HOME/build/android-ndk-r9c
fi fi
add_to PATH ~/.babel/bin # nimrod package manager
add_to PATH ~/.gem/ruby/2.1.0/bin