1 回答

TA貢獻(xiàn)1820條經(jīng)驗(yàn) 獲得超10個(gè)贊
嘗試重新安裝狂歡
這是我嘗試過的方法,它對我有用。
設(shè)置執(zhí)行路徑($GOPATH):
export GOPATH=/var/projects/go
安裝狂歡和命令:
go get github.com/revel/revel go get github.com/revel/cmd/revel
將 revel cmd 鏈接到 bin 目錄。因此該命令可能是可執(zhí)行的。
export PATH="$PATH:$GOPATH/bin
檢查狂歡是否有效。
revel
只需在命令行中輸入
輸出會是這樣的
Usage:
revel [OPTIONS] <command>
Application Options:
-v, --debug If set the logger is set to verbose
--historic-run-mode If set the runmode is passed a string not json
-X, --build-flags= These flags will be used when building the application. May be specified multiple times, only applicable for Build, Run,
Package, Test commands
Available commands:
build
clean
new
package
run
test
version
檢查狂歡版本:
revel version
輸出
Revel executing: displays the Revel Framework and Go version
Revel Framework : 0.21.0 (0.21.0 remote master branch)
Revel Cmd : 0.21.1 (0.21.1 remote master branch)
Revel Modules : 0.21.0 (0.21.0 remote master branch)
現(xiàn)在,您可以使用命令創(chuàng)建第一個(gè)項(xiàng)目
revel new myapp
輸出
Revel executing: create a skeleton Revel application
Your application has been created in:
/var/projects/go/src/myapp
You can run it with:
revel run -a myapp
- 1 回答
- 0 關(guān)注
- 199 瀏覽
添加回答
舉報(bào)