bee创建api应用遇到的问题
1:用bee api创建项目
api socialbatenews -conn="root:root@(127.0.0.1:3306)/spider?charset=utf8"
2:成功后我cd到目录进行run遇到如下问题
Last login: Sat Jul 2 10:14:43 on ttys000
apples-MacBook-Pro:~ carlos$ cd /Users/apple/Documents/gostud/src/github.com/socialbatenews/
apples-MacBook-Pro:socialbatenews carlos$ ls
conf docs models tests
controllers main.go routers
apples-MacBook-Pro:socialbatenews carlos$ bee run
-bash: bee: command not found
apples-MacBook-Pro:socialbatenews carlos$ source .bash_profile
-bash: .bash_profile: No such file or directory
apples-MacBook-Pro:socialbatenews carlos$ cd ~
apples-MacBook-Pro:~ carlos$ source .bash_profile
apples-MacBook-Pro:~ carlos$ cd /Users/apple/Documents/gostud/src/github.com/socialbatenews/
apples-MacBook-Pro:socialbatenews carlos$ bee run
bee :1.4.1
beego :1.6.1
Go :go version go1.6.2 darwin/amd64
2016/07/02 10:29:33 [INFO] Uses 'socialbatenews' as 'appname'
2016/07/02 10:29:33 [INFO] Initializing watcher...
2016/07/02 10:29:33 [TRAC] Directory(/Users/apple/Documents/gostud/src/github.com/socialbatenews/controllers)
2016/07/02 10:29:33 [TRAC] Directory(/Users/apple/Documents/gostud/src/github.com/socialbatenews)
2016/07/02 10:29:33 [TRAC] Directory(/Users/apple/Documents/gostud/src/github.com/socialbatenews/models)
2016/07/02 10:29:33 [TRAC] Directory(/Users/apple/Documents/gostud/src/github.com/socialbatenews/routers)
2016/07/02 10:29:33 [INFO] Start building...
main.go:4:2: no buildable Go source files in /Users/apple/Documents/gostud/src/github.com/socialbatenews/docs
2016/07/02 10:29:33 [ERRO] ============== Build failed ===================
我的相关环境是
go env
GOARCH="amd64"
GOBIN="/Users/apple/Documents/gostud/github.com/beego/bee"
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GOOS="darwin"
GOPATH="/Users/apple/Documents/gostud"
GORACE=""
GOROOT="/usr/local/go"
GOTOOLDIR="/usr/local/go/pkg/tool/darwin_amd64"
GO15VENDOREXPERIMENT="1"
CC="clang"
GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fno-common"
CXX="clang++"
CGO_ENABLED="1"
2:beeversion
apples-MacBook-Pro:socialbatenews carlos$ bee version
bee :1.4.1
beego :1.6.1
Go :go version go1.6.2 darwin/amd64
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
bee添加到环境变量了吗