dp20011
2016-04-10 09:43 阅读 416
已采纳

Golang:入门-“执行”不被识别为内部或外部命令”

Trying to get started with Go but I cant manage to set up the work environnement properly.

I've attached photos of everything I'd think you'd need to identify the problem, could someone tell me what's going on?

cmderror

gofolder

workenvironnementfolder

environnementroot

  • 点赞
  • 写回答
  • 关注问题
  • 收藏
  • 复制链接分享

3条回答 默认 最新

  • 已采纳
    dsdtszi0520538 dsdtszi0520538 2016-04-10 10:07

    EDITED for future reference.

    1. You set your 'GOROOT' wrong. Set it to C:\Go\

    2. Include C:\Go\bin to your 'Path'

    点赞 评论 复制链接分享
  • dongnunai3125 dongnunai3125 2017-03-05 06:27

    Run command "go env" and check the path for variable "gopath" that's where you should keep your project. Else where if you run go command you will get error "go is not recognized as internal or external command"

    点赞 评论 复制链接分享
  • dpbrrczhlwbv849228 dpbrrczhlwbv849228 2019-03-01 19:30

    Aside from @Xeph's answer, just make sure if you recently installed Go that you use a fresh terminal/cmd window.

    点赞 评论 复制链接分享

相关推荐