Skip to content

Commit 3322e45

Browse files
committed
fix: empty GOPATH causes malformed PATH. #167
1 parent c2c9715 commit 3322e45

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

install.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ function main() {
5555
#!/bin/sh
5656
# g shell setup
5757
export GOROOT="${HOME}/.g/go"
58+
[ -z "$GOPATH" ] && export GOPATH="${HOME}/go"
5859
export PATH="${HOME}/.g/bin:${GOROOT}/bin:${GOPATH}/bin:$PATH"
5960
export G_MIRROR=https://golang.google.cn/dl/
6061
EOF

0 commit comments

Comments
 (0)