-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathprofile.sh
72 lines (56 loc) · 1.92 KB
/
profile.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
# ~/.profile
if [ -n "${BASH_VERSION}" ]; then
[ -f "${HOME}/.bashrc" ] && . "${HOME}/.bashrc"
elif [ -n "${ZSH_VERSION}" ]; then
[ -f "${HOME}/.zshrc" ] && . "${HOME}/.zshrc"
fi
# SSH Agent
export SSH_AUTH_SOCK="${XDG_RUNTIME_DIR}/ssh-agent.socket"
# Text Editor
export EDITOR="nvim"
export VISUAL="${EDITOR}"
# User binaries
[ -d "${HOME}/.local/bin" ] && PATH="${HOME}/.local/bin:${PATH}"
# Qt theme management
if command -v qt6ct > /dev/null 2>&1; then
export QT_QPA_PLATFORMTHEME="qt6ct"
elif command -v qt5ct > /dev/null 2>&1; then
export QT_QPA_PLATFORMTHEME="qt5ct"
fi
# Erlang / Elixir
export ERL_AFLAGS="-kernel shell_history enabled"
# Go
export GOPATH="${HOME}/.golang"
export GOBIN="${GOPATH}/bin"
[ -d "${GOBIN}" ] && PATH="${GOBIN}:${PATH}"
# Google Cloud SDK
# https://cloud.google.com/iap/docs/using-tcp-forwarding#increasing_the_tcp_upload_bandwidth
export CLOUDSDK_PYTHON_SITEPACKAGES=1
if [ -n "${ZSH_VERSION}" ]; then
[ -f /opt/google-cloud-cli/completion.zsh.inc ] && source /opt/google-cloud-cli/completion.zsh.inc
[ -f /opt/google-cloud-cli/path.zsh.inc ] && source /opt/google-cloud-cli/path.zsh.inc
fi
# Java / GraalVM
GRAALVM_HOME=/usr/lib/jvm/java-11-graalvm
[ -d ${GRAALVM_HOME} ] && export GRAALVM_HOME
# NodeJS
[ -d "${HOME}/.node_modules/bin" ] && PATH="${HOME}/.node_modules/bin:${PATH}"
if [ -f /usr/share/nvm/init-nvm.sh ]
then
# nvm is installed system-wide
. /usr/share/nvm/init-nvm.sh
else
# nvm is installed for the current user
export NVM_DIR="${HOME}/.nvm"
[ -s "${NVM_DIR}/nvm.sh" ] && . "${NVM_DIR}/nvm.sh"
if [ -n "${BASH_VERSION}" ]; then
[ -s "${NVM_DIR}/bash_completion" ] && . "${NVM_DIR}/bash_completion"
fi
fi
# Rust
[ -d "${HOME}/.cargo/bin" ] && PATH="${HOME}/.cargo/bin:${PATH}"
# Snaps
SNAPBIN=/snap/bin
[ -d ${SNAPBIN} ] && PATH="${SNAPBIN}:${PATH}"
# Terraform Plugin Cache
export TF_PLUGIN_CACHE_DIR="${HOME}/.terraform.d/plugins"