dongqing220586 2018-11-25 05:18
浏览 334

git push heroku错误:找不到软件包“ github.com/astaxie/beego”

I want to deploy beego on Heroku. The steps is:

  1. Create new project with bee tool

    $ bee new myproject

  2. Change to GOPATH

    $ cd %GOPTH%\src

  3. Clone my heroku app.

    $ git clone https://git.heroku.com/{APP_NAME}.git

  4. Copy all files from my beego project to heroku app folder.

    $ xcopy %GOPATH%\src\myproject\* %GOPATH%\src\{APP_NAME} /s /i

  5. Fetching not already dependency

    $ govendor fetch github.com/astaxie/beego

  6. Push source code

    $ git push heroku master

remote: -----> Go app detected remote: -----> Checking vendor/vendor.json file. remote: !! The 'heroku.goVersion' field is not specified in 'vendor/vendor.json'. remote: !! remote: !! Defaulting to go1.11.2 remote: !! remote: !! For more details see: https://devcenter.heroku.com/articles/go-apps-with-govendor#build-configuration remote: !! remote: -----> Using go1.11.2 remote: !! Installing package '.' (default) remote: !! remote: !! To install a different package spec set 'heroku.install' in 'vendor/vendor.json' remote: !! remote: !! For more details see: https://devcenter.heroku.com/articles/go-apps-with-govendor#build-configuration remote: !! remote: -----> Fetching any unsaved dependencies (govendor sync) remote: -----> Running: go install -v -tags heroku . remote: main.go:5:2: cannot find package "github.com/astaxie/beego" in any of: remote: /tmp/tmp.XOWyIa6r7h/.go/src/github.com/heroku/go-getting-started/vendor/github.com/astaxie/beego (vendor tree) remote: /app/tmp/cache/go1.11.2/go/src/github.com/astaxie/beego (from $GOROOT) remote: /tmp/tmp.XOWyIa6r7h/.go/src/github.com/astaxie/beego (from $GOPATH) remote: main.go:4:2: cannot find package "myproject/routers" in any of: remote: /tmp/tmp.XOWyIa6r7h/.go/src/github.com/heroku/go-getting-started/vendor/myproject/routers (vendor tree) remote: /app/tmp/cache/go1.11.2/go/src/myproject/routers (from $GOROOT) remote: /tmp/tmp.XOWyIa6r7h/.go/src/myproject/routers (from $GOPATH) remote: ! Push rejected, failed to compile Go app.

I don't know how to fix it. Has anyone encountered the similar problem?


Environment

  • Windows 10
  • go version go1.9.3 windows/amd64
  • Beego : 1.10.1
  • 写回答

0条回答 默认 最新

    报告相同问题?

    悬赏问题

    • ¥15 三菱伺服电机按启动按钮有使能但不动作
    • ¥20 为什么我写出来的绘图程序是这样的,有没有lao哥改一下
    • ¥15 js,页面2返回页面1时定位进入的设备
    • ¥200 关于#c++#的问题,请各位专家解答!网站的邀请码
    • ¥50 导入文件到网吧的电脑并且在重启之后不会被恢复
    • ¥15 (希望可以解决问题)ma和mb文件无法正常打开,打开后是空白,但是有正常内存占用,但可以在打开Maya应用程序后打开场景ma和mb格式。
    • ¥15 绘制多分类任务的roc曲线时只画出了一类的roc,其它的auc显示为nan
    • ¥20 ML307A在使用AT命令连接EMQX平台的MQTT时被拒绝
    • ¥20 腾讯企业邮箱邮件可以恢复么
    • ¥15 有人知道怎么将自己的迁移策略布到edgecloudsim上使用吗?