1
0
mirror of https://github.com/kremalicious/dotfiles.git synced 2024-12-22 09:13:22 +01:00
dotfiles/exports

60 lines
1.8 KiB
Plaintext
Raw Normal View History

2019-08-19 00:37:26 +02:00
#!/usr/bin/env bash
2019-08-18 02:07:17 +02:00
# Prefer US English and use UTF-8
export LC_ALL="en_US.UTF-8"
export LANG="en_US"
# ---------------------------------------------------
# PATH
# ---------------------------------------------------
2023-01-23 19:05:14 +01:00
# Homebrew path differs between Intel/Apple Silicon
# See https://apple.stackexchange.com/questions/437618/why-is-homebrew-installed-in-opt-homebrew-on-apple-silicon-macs
# Hardcoded paths because `brew --prefix ...` is slow
if [[ $(uname -m) == 'arm64' ]]; then
PATH_HOMEBREW=/opt/homebrew
else
PATH_HOMEBREW=/usr/local
fi
2023-01-24 14:15:02 +01:00
export PATH_HOMEBREW
2023-01-23 19:05:14 +01:00
PATH_OPENSSL=$PATH_HOMEBREW/opt/openssl/bin
2020-11-02 23:31:29 +01:00
# PATH_RUBY=$(brew --prefix ruby)/bin
2023-01-23 19:05:14 +01:00
# PATH_GEMS=$PATH_HOMEBREW/lib/ruby/gems/2.6.0/bin
PATH_PYTHON=$PATH_HOMEBREW/opt/python/libexec/bin
PATH_GO=$PATH_HOMEBREW/opt/go/libexec/bin
2020-11-02 23:31:29 +01:00
#PATH_RUST=$HOME/.cargo/bin
2019-08-19 00:37:26 +02:00
2023-04-01 00:24:26 +02:00
export GOPATH=$HOME/.go
export PATH=$HOME/.bin:$PATH_HOMEBREW/bin:$PATH_OPENSSL:$PATH_PYTHON:$GOPATH/bin:$PATH_GO:$PATH
2019-08-18 02:07:17 +02:00
# define CDPATHs which are autocompleted from when doing cd
export CDPATH=$CDPATH:~/Code
# nvm
2023-01-23 19:05:14 +01:00
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"
2019-08-18 14:05:36 +02:00
# defer loading until needed for faster shell startup
2023-01-23 19:05:14 +01:00
#declare -a NODE_GLOBALS=(`find ~/.nvm/versions/node -maxdepth 3 -type l -wholename '*/bin/*' | xargs -n1 basename | sort | uniq`)
2021-02-16 21:42:11 +01:00
2023-01-23 19:05:14 +01:00
#NODE_GLOBALS+=("node")
#NODE_GLOBALS+=("nvm")
2019-08-18 14:05:36 +02:00
2023-01-23 19:05:14 +01:00
#load_nvm () {
# export NVM_DIR="$HOME/.nvm"
# [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"
#}
2019-08-18 14:05:36 +02:00
2023-01-23 19:05:14 +01:00
#for cmd in "${NODE_GLOBALS[@]}"; do
# eval "${cmd}(){ unset -f ${NODE_GLOBALS}; load_nvm; ${cmd} \$@ }"
#done
2019-08-18 02:07:17 +02:00
# pip should only run if there is a virtualenv currently activated
2021-02-16 21:42:11 +01:00
export PIP_REQUIRE_VIRTUALENV=true
2019-08-18 02:07:17 +02:00
# cache pip-installed packages to avoid re-downloading
export PIP_DOWNLOAD_CACHE=$HOME/.pip/cache
2023-01-23 19:05:14 +01:00
export GPG_TTY=$(tty)