第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號安全,請及時(shí)綁定郵箱和手機(jī)立即綁定
已解決430363個(gè)問題,去搜搜看,總會有你想問的

無法從 Go 安裝 Revel 框架

無法從 Go 安裝 Revel 框架

Go
慕容708150 2023-04-17 14:29:32
我試圖安裝Revel Framework。我按照文檔中給出的所有步驟進(jìn)行操作,但每當(dāng)我嘗試運(yùn)行 Revel 命令時(shí),它都會拋出恐慌錯(cuò)誤。以下是我正在執(zhí)行環(huán)境路徑的步驟:export GOROOT=/usr/local/goexport GOPATH=/Users/<username>/Desktop/gocodeexport PATH="/Users/<username>/gocode/bin:$PATH"安裝 Revelgo get github.com/revel/revelgo get github.com/revel/cmd/revelexport PATH="$PATH:$GOPATH/bin"當(dāng)我運(yùn)行狂歡版本時(shí),它顯示:panic: runtime error: slice bounds out of rangegoroutine 1 [running]:github.com/revel/cmd/model.(*CommandConfig).UpdateImportPath(0xc4200961c0, 0x20)    /Users/amitsharma/Desktop/gocode/src/github.com/revel/cmd/model/command_config.go:122 +0x907main.main()    /Users/amitsharma/Desktop/gocode/src/github.com/revel/cmd/revel/revel.go:133 +0x243當(dāng)我跑步時(shí)revel run -a my-app表明ERROR 19:34:59 harness.go:231: Could not start application              error="revel/harness: app died reason: exit status 2"INFO  19:34:59 watcher.go:272: Watcher: Recording error last build, setting rebuild on error="App failed to start up: revel/harness: app died reason: exit status 2"INFO  19:34:59 watcher.go:277: Rebuilt, result                          error="App failed to start up: revel/harness: app died reason: exit status 2"我的去版本go version go1.10.3 darwin/amd64我的環(huán)境GOARCH="amd64"GOBIN=""GOCACHE="/Users/amitsharma/Library/Caches/go-build"GOEXE=""GOHOSTARCH="amd64"GOHOSTOS="darwin"GOOS="darwin"GOPATH="/Users/<username>/Desktop/gocode"GORACE=""GOROOT="/usr/local/go"GOTMPDIR=""GOTOOLDIR="/usr/local/go/pkg/tool/darwin_amd64"GCCGO="gccgo"CC="clang"CXX="clang++"CGO_ENABLED="1"CGO_CFLAGS="-g -O2"CGO_CPPFLAGS=""CGO_CXXFLAGS="-g -O2"CGO_FFLAGS="-g -O2"CGO_LDFLAGS="-g -O2"PKG_CONFIG="pkg-config"GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/0d/pkfrs5cj0v57xgsnwvb2kb580000gn/T/go-build028697826=/tmp/go-build -gno-record-gcc-switches -fno-common"
查看完整描述

1 回答

?
拉莫斯之舞

TA貢獻(xiàn)1820條經(jīng)驗(yàn) 獲得超10個(gè)贊

嘗試重新安裝狂歡

這是我嘗試過的方法,它對我有用。

  1. 設(shè)置執(zhí)行路徑($GOPATH):

export GOPATH=/var/projects/go
  1. 安裝狂歡和命令:

  go get github.com/revel/revel  go get github.com/revel/cmd/revel
  1. 將 revel cmd 鏈接到 bin 目錄。因此該命令可能是可執(zhí)行的。

export PATH="$PATH:$GOPATH/bin
  1. 檢查狂歡是否有效。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


查看完整回答
反對 回復(fù) 2023-04-17
  • 1 回答
  • 0 關(guān)注
  • 199 瀏覽

添加回答

舉報(bào)

0/150
提交
取消
微信客服

購課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動學(xué)習(xí)伙伴

公眾號

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號