douke9379 2019-01-21 18:41
浏览 31

将html文件复制到供应商文件夹

Use Case: I have Proj A and Proj B. Proj B depends on Proj A. I am using Go Modules for dependency management and go mod vendor for generating the vendor folder. Proj A is inside the vendor folder of Proj B.

Issue: In Proj A, I have an HTML file. The HTML file is not copied to the vendor folder.

How can I force to copy the HTML file to the vendor folder so that I can use in Proj B?

  • 写回答

1条回答 默认 最新

  • duanpiangeng8958 2019-01-21 20:00
    关注

    A workaround for this issue is to have a dummy go file and go function in the html folder, and call the dummy function somewhere in the code. This makes the go mod vendor to copy the folder to the vendor folder. Not a cleaner way, until Go mod adds something like non-go=true option in deps.

    评论

报告相同问题?

悬赏问题

  • ¥15 c语言怎么用printf(“\b \b”)与getch()实现黑框里写入与删除?
  • ¥20 怎么用dlib库的算法识别小麦病虫害
  • ¥15 华为ensp模拟器中S5700交换机在配置过程中老是反复重启
  • ¥15 java写代码遇到问题,求帮助
  • ¥15 uniapp uview http 如何实现统一的请求异常信息提示?
  • ¥15 有了解d3和topogram.js库的吗?有偿请教
  • ¥100 任意维数的K均值聚类
  • ¥15 stamps做sbas-insar,时序沉降图怎么画
  • ¥15 买了个传感器,根据商家发的代码和步骤使用但是代码报错了不会改,有没有人可以看看
  • ¥15 关于#Java#的问题,如何解决?