go运行失败

1、Build Error: go build -o d:\Projects\GoProject\.vscode\__debug_bin.exe -gcflags all=-N -l . package .: no Go files in d:\Projects\GoProject\.vscode (exit status 1)

将 package code 更改为package main

2、go: go.mod file not found in current directory or any parent directory;

cmd:  go env -w GO111MODULE=auto

 

 

posted @ 2022-03-25 10:02  韩梦芫  阅读(337)  评论(0编辑  收藏  举报