2023-01-24 20:52:40 -08:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
2023-01-24 20:31:32 -08:00
|
|
|
### Source .bashrc if it is present
|
|
|
|
if [ -f "$HOME/.bashrc" ]; then
|
|
|
|
. "$HOME/.bashrc"
|
2023-08-07 22:29:21 -07:00
|
|
|
elif [ -f "${XDG_CONFIG_HOME:-$HOME/.config}/shell/exports.sh" ]; then
|
|
|
|
. "${XDG_CONFIG_HOME:-$HOME/.config}/shell/exports.sh"
|
2023-01-24 20:31:32 -08:00
|
|
|
fi
|
|
|
|
|
|
|
|
### XDG
|
2023-08-07 22:29:21 -07:00
|
|
|
export XDG_CONFIG_HOME="${XDG_CONFIG_HOME:-$HOME/.config}"
|
|
|
|
export XDG_CACHE_HOME="${XDG_CACHE_HOME:-$HOME/.cache}"
|
|
|
|
export XDG_DATA_HOME="${XDG_DATA_HOME:-$HOME/.local/share}"
|
2023-01-24 20:31:32 -08:00
|
|
|
|
|
|
|
### Ensure Homebrew PATHs
|
2023-01-24 20:59:29 -08:00
|
|
|
if [ -d "/home/linuxbrew/.linuxbrew/bin" ]; then
|
2023-01-24 20:31:32 -08:00
|
|
|
export HOMEBREW_PREFIX="/home/linuxbrew/.linuxbrew"
|
|
|
|
export HOMEBREW_CELLAR="/home/linuxbrew/.linuxbrew/Cellar"
|
|
|
|
export HOMEBREW_REPOSITORY="/home/linuxbrew/.linuxbrew/Homebrew"
|
|
|
|
export PATH="/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin${PATH+:$PATH}"
|
|
|
|
export MANPATH="/home/linuxbrew/.linuxbrew/share/man${MANPATH+:$MANPATH}:"
|
|
|
|
export INFOPATH="/home/linuxbrew/.linuxbrew/share/info:${INFOPATH:-}"
|
|
|
|
export WHALEBREW_INSTALL_PATH="/home/linuxbrew/.linuxbrew/whalebrew"
|
2023-01-24 20:59:29 -08:00
|
|
|
elif [ -f "/usr/local/bin/brew" ]; then
|
2023-01-24 20:31:32 -08:00
|
|
|
eval "$(/usr/local/bin/brew shellenv)"
|
2023-01-24 20:59:29 -08:00
|
|
|
elif [ -f "/opt/homebrew/bin/brew" ]; then
|
|
|
|
eval "$(/opt/homebrew/bin/brew shellenv)"
|
2023-01-24 20:31:32 -08:00
|
|
|
fi
|
2023-07-10 22:05:07 -07:00
|
|
|
export HOMEBREW_NO_ANALYTICS=1
|
2023-01-24 20:31:32 -08:00
|
|
|
|
2023-02-01 18:15:14 -08:00
|
|
|
### SDKMan
|
2023-08-07 22:29:21 -07:00
|
|
|
export SDKMAN_DIR="${XDG_DATA_HOME:-$HOME/.local/share}/sdkman"
|
2023-02-01 18:15:14 -08:00
|
|
|
|
2023-01-30 21:43:15 -08:00
|
|
|
### Volta
|
2023-08-07 22:29:21 -07:00
|
|
|
export VOLTA_HOME="${XDG_DATA_HOME:-$HOME/.local/share}/volta"
|
2023-01-30 21:43:15 -08:00
|
|
|
export PATH="$VOLTA_HOME/bin:$PATH"
|
|
|
|
|
2023-01-24 20:31:32 -08:00
|
|
|
### Ensure ~/.local/bin in PATH
|
2023-01-24 20:52:40 -08:00
|
|
|
export PATH="$HOME/.local/bin:$PATH"
|