安裝beego 安裝bee工具git
go get github.com/astaxie/beego
go get github.com/beego/bee
問題github
src目錄下執行瀏覽器
../bin/bee new beegonew
2019/04/04 17:08:48 ERROR ▶ 0001 You need to set GOPATH environment variable
______
| ___ \
| |_/ / ___ ___
| ___ \ / _ \ / _ \
| |_/ /| __/| __/
\____/ \___| \___| v1.10.0
2019/04/04 17:08:48 FATAL ▶ 0002 GOPATH environment variable is not set or empty
緣由工具
用 echo $GOPATH
若是打印 /Users/chenbao/go/bin ;
對於 bee 來講 你的 $GOPATH 纔算設置好了,code
解決辦法get
export GOPATH=你的工做路徑 #最好用絕對地址,如:/Users/mac/go
../../bin/bee run 監聽8080端口 瀏覽器訪問 localhost:8080it