会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
ruixing
博客园
首页
新随笔
联系
订阅
管理
1
2
3
4
5
下一页
2020年11月18日
Go Mod 添加私有仓库
摘要: 添加免密认证 # cat ~/.ssh/config # gitlab Host gitlab.xxx.com Port 22 HostName gitlab.xxx.com PreferredAuthentications publickey IdentityFile your_private_k
阅读全文
posted @ 2020-11-18 15:10 ruixing
阅读(4490)
评论(2)
推荐(0)
2020年10月13日
gorm结构生成
摘要: 从数据库导出gorm使用的数据结构 go get -u -v github.com/xxjwxc/gormt@master gormt -H=数据库地址 -d=数据库名 -p=密码 -u=用户 --port=3306 -F=true
阅读全文
posted @ 2020-10-13 10:54 ruixing
阅读(833)
评论(0)
推荐(0)
从GitLab使用go get
摘要: 使用私有仓库gitlab进行go依赖管理(go mod / go get) // 编辑git配置文件 ~/.gitconfig [url "git@gitlab.***.com:"] insteadOf = https://gitlab.***.com // 配置环境变量 GOPRIVATE=git
阅读全文
posted @ 2020-10-13 10:27 ruixing
阅读(1453)
评论(0)
推荐(0)
2020年9月20日
Interface
摘要: Go Interface是什么? 简单来说,是一组方法的集合,也是一种类型 Go允许没有任何方法的interface,称为空interface,可以认为任何的类型都实现了空interface 如果一个类型A实现了如下Interface GetSay的方法,我们就认为A实现了该Interface,在实
阅读全文
posted @ 2020-09-20 15:44 ruixing
阅读(307)
评论(0)
推荐(0)
2020年9月16日
go-micro
摘要: go get github.com/micro/micro/v3 micro login # admin # micro micro service micro new helloworld micro run helloworld
阅读全文
posted @ 2020-09-16 22:36 ruixing
阅读(158)
评论(0)
推荐(0)
Go Tools
摘要: protoc-gen-micro 这是用于micro的protobuf代码生成 项目地址:https://github.com/micro/micro/tree/master/cmd/protoc-gen-micro protoc-go-inject-tag proto struct对应的json定
阅读全文
posted @ 2020-09-16 13:35 ruixing
阅读(260)
评论(0)
推荐(0)
2020年9月10日
Context
摘要: Context 1、Context取消goroute任务 2、Context进行超时控制 3、Context传递普通参数 Context使用 context.WithCancel 1、返回一个cancel函数,调用cancel函数的时候,会触发context.Done()函数 2、当你执行一个后台任
阅读全文
posted @ 2020-09-10 15:48 ruixing
阅读(709)
评论(0)
推荐(0)
2020年9月7日
godoc使用
摘要: 安装godoc go get -v golang.org/x/tools/cmd/godoc godoc帮助信息 godoc --help wangruixing@MacBook-Pro usage: godoc -http=localhost:6060 -analysis string # 只支持
阅读全文
posted @ 2020-09-07 14:19 ruixing
阅读(1192)
评论(0)
推荐(0)
gin模板使用
摘要: gin模板使用,参考链接 https://www.bookstack.cn/read/go42/content-42_35_template.md
阅读全文
posted @ 2020-09-07 10:26 ruixing
阅读(980)
评论(0)
推荐(0)
2020年9月2日
GitLab CI/CD
摘要: CI/CD 持续集成CI(尽快发现错误、减少集成问题,避免复杂问题) 合并开发人员正在开发编写的所有代码的一种做法 一天内进行多次合并和提交代码 从存储库或生产环境中进行构建和自动化测试,以确保没有集成问题并及早发现任何问题 持续交付CD(每次更改都可发布,降低每次发布风险,更加频繁交付价值,快速频
阅读全文
posted @ 2020-09-02 09:26 ruixing
阅读(1036)
评论(0)
推荐(1)
1
2
3
4
5
下一页
公告