Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
Clivern committed Jul 12, 2022
1 parent 97120b9 commit d7bcbe2
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .go-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.17
1.18.1
10 changes: 8 additions & 2 deletions bin/shims/go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@ GOENV_ROOT="/Users/joedoe/.goenv" \
GOBIN=$GO_VERSION_PATH/bin \
"$GO_VERSION_PATH/bin/$GO_BINARY_NAME" "$@"

[[ "$@" =~ "get" ]] && ( goenv rehash )
if [[ "$@" =~ 'get' ]]
then
goenv rehash
fi

[[ "$@" =~ "install" ]] && ( goenv rehash )
if [[ "$@" =~ 'install' ]]
then
goenv rehash
fi
12 changes: 10 additions & 2 deletions core/module/const.go
Original file line number Diff line number Diff line change
Expand Up @@ -241,9 +241,16 @@ GOENV_ROOT="%s" \
GOBIN=$GO_VERSION_PATH/bin \
"$GO_VERSION_PATH/bin/$GO_BINARY_NAME" "$@"
[[ "$@" =~ "get" ]] && ( goenv rehash )
if [[ "$@" =~ 'get' ]]
then
goenv rehash
fi
if [[ "$@" =~ 'install' ]]
then
goenv rehash
fi
[[ "$@" =~ "install" ]] && ( goenv rehash )
`

// binaryShimContent shim other go binaries
Expand All @@ -257,6 +264,7 @@ GOENV_ROOT="%s" \
GOPATH=$GO_VERSION_PATH \
GOBIN=$GO_VERSION_PATH/bin \
"$GO_VERSION_PATH/bin/$GO_BINARY_NAME" "$@"
`

// getDownloadURL returns the download link
Expand Down

0 comments on commit d7bcbe2

Please sign in to comment.