常用的go module replace设置

  1. 简单记录,不定期更新

简单记录,不定期更新

  1. 如果是golang.org/x/的包,一般替换为:github.com/golang/ 即可。
replace golang.org/x/text => github.com/golang/text latest
replace golang.org/x/net => github.com/golang/net latest
replace golang.org/x/tools => github.com/golang/tools latest
replace golang.org/x/image => github.com/golang/image latest
replace golang.org/x/sys => github.com/golang/sys latest
replace golang.org/x/crypto => github.com/golang/crypto latest
replace golang.org/x/sync => github.com/golang/sync latest
replace golang.org/x/exp => github.com/golang/exp latest
replace golang.org/x/lint => github.com/golang/lint latest
replace google.golang.org/grpc => github.com/grpc/grpc-go latest
replace google.golang.org/api => github.com/googleapis/google-api-go-client latest
replace golang.org/x/oauth2 => github.com/golang/oauth2 latest
replace cloud.google.com/go => github.com/GoogleCloudPlatform/google-cloud-go latest
replace google.golang.org/appengine => github.com/golang/appengine latest
replace golang.org/x/mobile => github.com/golang/mobile latest
replace golang.org/x/time => github.com/golang/time latest
  1. code.google.com (不能直接替换为github.com/golang,不知道为什么)
replace code.google.com/p/go.benchmarks => golang.org/x/benchmarks
replace code.google.com/p/go.blog => golang.org/x/blog
replace code.google.com/p/go.crypto => golang.org/x/crypto
replace code.google.com/p/go.exp => golang.org/x/exp
replace code.google.com/p/go.image => golang.org/x/image
replace code.google.com/p/go.mobile => golang.org/x/mobile
replace code.google.com/p/go.net => golang.org/x/net
replace code.google.com/p/go.sys => golang.org/x/sys
replace code.google.com/p/go.talks => golang.org/x/talks
replace code.google.com/p/go.text => golang.org/x/text
replace code.google.com/p/go.tools => golang.org/x/tools

转载请注明来源,欢迎对文章中的引用来源进行考证,欢迎指出任何有错误或不够清晰的表达。可以在下面评论区评论,也可以邮件至 irvin.em@live.com

文章标题:常用的go module replace设置

文章字数:360

本文作者:dino

发布时间:2019-11-18, 12:14:01

最后更新:2019-12-04, 17:42:51

原始链接:https://blog.walkbc.com/2019/11/18/commonGoModuleReplace/

版权声明: "署名-非商用-相同方式共享 4.0" 转载请保留原文链接及作者。

目录