搭建go开发环境时,出现GoSublime error: MarGo build failed的问题

在安装问go语言开发工具,Sublime Text Build 3083之后,再安装gocode和margo时,在安装margo那一步卡住了,出现了以下问题:


GoSublime error: MarGo build failed
|                > This is possibly a bug or miss-configuration of your environment.
|                > For more help, please file an issue with the following build output
|                > at: https://github.com/DisposaBoy/GoSublime/issues/new
|                > or alternatively, you may send an email to: gosublime@dby.me
|                > 
|                > 
|                > cmd: `['D:\\Program Files\\Go\\bin\\go.exe', 'build', '-v', '-x', '-o', 'gosublime.margo_r14.12.06-1_go1.4.2.exe', 'gosubli.me/margo']`
|                > stdout: ``
|                > stderr: `WORK=~\AppData\Local\Temp\go-build300617651
|                > runtime
|                > go build runtime: windows/amd64 must be bootstrapped using make.bat`
|                > exception: `None`
|   install state: busy
| sublime.version: 3083
| sublime.channel: stable
|       about.ann: a14.02.25-1
|   about.version: r14.12.06-1
|         version: r14.12.06-1
|        platform: windows-x64
|            ~bin: D:\software\sublime text\Sublime Text Build 3083 x64\Data\Packages\User\GoSublime\windows-x64\bin
|       margo.exe: ~bin\gosublime.margo_r14.12.06-1_go1.4.2.exe (missing)
|          go.exe: D:\Program Files\Go\bin\go.exe (ok)
|      go.version: go1.4.2
|          GOROOT: D:\Program Files\Go
|          GOPATH: H:/go/development
|           GOBIN: (not set) (should usually be `(not set)`)
|       set.shell: []
|       env.shell: 
|       shell.cmd: ['C:\\Windows\\system32\\cmd.exe', '/C', '${CMD}']


关键在于:
MarGo build failed
go get github.com/DisposaBoy/MarGo 之后才知道,这个工具已经被作者清理了,因此在github上搜索 MarGo之后,有几个结果


我选择了第一个搜索结果,(安装完之后可以使用但是和原来的MarGo的具体区别还没研究),可以使用这句语句在命令行输入go get github.com/slene/margo来安装


,安装完成之后在GOPATH目录下的bin文件夹会生成margo.exe的可执行文件,再将该可执行文件拷贝到Sublime Text 3083安装路径Data\Packages\User\GoSublime\windows-x64\bin下,并将文件名改为以下标为红色字的名字

<pre name="code" class="plain">               > cmd: `['D:\\Program Files\\Go\\bin\\go.exe', 'build', '-v', '-x', '-o', '<span style="color:#ff0000;">gosublime.margo_r14.12.06-1_go1.4.2.exe</span>', 'gosubli.me/margo']`

 

以下是我的电脑上的路径,仅供参考


重新启动sublime Text 3083即可



  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值