Skip to content

Commit 8c18aef

Browse files
authored
Fix setup with GOPATH env var not set (#45)
1 parent cae9ed9 commit 8c18aef

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

setup.sh

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,7 @@ go mod tidy
1111
go get github.com/webui-dev/go-webui/v2@main
1212
go get github.com/webui-dev/webui@main > /dev/null 2>&1
1313

14-
if [ -z "$GOPATH" ]; then
15-
go_path=$HOME/go
16-
else
17-
go_path=$GOPATH
18-
fi
14+
go_path="${GOPATH:-$(go env GOPATH)}"
1915

2016
go_webui_full_version=$(grep "github.com/webui-dev/go-webui/v2" go.sum | awk '{print $2}' | head -n 1)
2117
webui_full_version=$(grep "github.com/webui-dev/webui" go.sum | awk '{print $2}' | head -n 1)

0 commit comments

Comments
 (0)