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 linux驱动,linux应用,多线程
    • ¥20 我要一个分身加定位两个功能的安卓app
    • ¥15 基于FOC驱动器,如何实现卡丁车下坡无阻力的遛坡的效果
    • ¥15 IAR程序莫名变量多重定义
    • ¥15 (标签-UDP|关键词-client)
    • ¥15 关于库卡officelite无法与虚拟机通讯的问题
    • ¥15 目标检测项目无法读取视频
    • ¥15 GEO datasets中基因芯片数据仅仅提供了normalized signal如何进行差异分析
    • ¥100 求采集电商背景音乐的方法
    • ¥15 数学建模竞赛求指导帮助