Skip to content

Commit f939162

Browse files
authored
Merge pull request #1152 from ismail/ismail-patch-1
If GOPATH is empty check for the value of go env GOPATH
2 parents 8775ba7 + 407dcda commit f939162

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

plugin/go.vim

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ command! -nargs=? -complete=dir GoPath call go#path#GoPath(<f-args>)
3232
" target install directory. GoInstallBinaries doesn't install binaries if they
3333
" exist, to update current binaries pass 1 to the argument.
3434
function! s:GoInstallBinaries(updateBinaries)
35-
if $GOPATH == ""
35+
if $GOPATH == "" && go#util#gopath() == ""
3636
echohl Error
3737
echomsg "vim.go: $GOPATH is not set"
3838
echohl None

0 commit comments

Comments
 (0)