我爱占星网 我爱占星网
首页
编程
java
php
前端
首页 编程 java php 前端

go.mod文件不在root中

I want my project structure like this

repo/
├── app-sv        // my Go api server
│   └── go.mod    // go.mod not working in non-root folder
├── app-cl        // my frontend
├── go.mod        // go.mod is working here
└── README.md

Go modules are not working in a non-root folder, the obvious alternative solution is to create 2 different repo. Is this possible to do? Maybe I'm missing some trivial setup.

EDIT: here's the error

近期文章

  • 如何添加开始日期和结束日期的开始验证? [关闭]
  • 在gonum / plot中的单个图像中有多个图
  • Go:无法在go例程中创建服务器
  • * [] User或[] * User最好的方法是什么? [重复]
  • 为什么这会给我一个不确定的错误?
  • 试图了解go build -tags static
  • Go lang中的线程同步
  • 转到:调用函数时如何使用命名参数?
  • 避免在具有接口的范围内的goroutine中进行数据争夺
  • 理解golang中的并发性的最佳资源是什么? [关闭]
  • 在Go中使用变量解密字符串
  • 为什么我不能将纪元时间转换为字符串?
  • 使用var vs function定义函数
  • 找不到attrmgr(来自$ GOROOT)和$ GOPATH?
  • 如何在Go中进行React Server Side渲染
  • 处理多个WebSocket连接
  • 打印和Go中打印之间的区别[重复]
  • Push ConsumerConfig的最佳线程计数值是多少? [关闭]
  • 使用goquery从html提取文本,但结果仍包含html标记
  • 我如何进一步理解Go为什么以这种方式处理错误? [关闭]

Copyright ©2022 我爱占星 All Rights Reserved.

浙ICP备2022030071号-1

部分图文来自网络,如有侵犯您的版权,请告诉我们删除

友情链接:代码精华