delete extra go path handling (seems to be fixed in new version) and python path handling for macos

This commit is contained in:
James Dixon 2024-01-15 10:42:44 -05:00
parent 8d819221ff
commit 7b2471e8b0

View File

@ -333,26 +333,6 @@ src_pyenv() {
fi fi
} }
# go
export GOROOT="/usr/local/go"
[ -d "$GOROOT/bin" ] && appendpath "$GOROOT/bin"
export GO111MODULE=on
export GOPATH="$HOME/go"
if command -v go &> /dev/null; then
# change default go path
export GOPATH="$HOME/.go"
[ -d "$HOME/go" ] && mv "$HOME/go" "$HOME/.go"
# change default go working dir and mod dir
export GOWD="$GOPATH/src/github.com/lemonase"
[ ! -d "$GOWD" ] && mkdir -p "$GOWD"
export GOMOD="$GOPATH/pkg/mod/github.com/lemonase/"
# add go path bin directory to path
[ -d "$GOPATH/bin" ] && appendpath "$GOPATH/bin"
fi
# rust # rust
[ -d "$HOME/.cargo" ] && appendpath "$HOME/.cargo/bin" [ -d "$HOME/.cargo" ] && appendpath "$HOME/.cargo/bin"
@ -362,8 +342,8 @@ case "$OSTYPE" in
# homebrew # homebrew
[ -d "/opt/homebrew/bin" ] && appendpath "/opt/homebrew/bin" [ -d "/opt/homebrew/bin" ] && appendpath "/opt/homebrew/bin"
# python3 (macOS) # python3 (macOS)
[ -d "$HOME/Library/Python/3.8/bin" ] && appendpath "$HOME/Library/Python/3.8/bin" LATEST_PY=$(find "$HOME/Library/Python" -type d -maxdepth 1 | sort -V | tail -n 1)
[ -d "$HOME/Library/Python/3.9/bin" ] && appendpath "$HOME/Library/Python/3.9/bin" [ -d "$LATEST_PY/bin" ] && appendpath "$LATEST_PY/bin"
# gui things # gui things
alias o="open" alias o="open"
;; ;;