GoLand

Golang课件索引-Golang语言基础课件,这里都有

久未见 提交于 2020-03-25 15:34:29
3 月,跳不动了?>>> go学习pdf课件,大家可以收藏页面以免文件丢失 Go语言发展历史、核心特性及学习路线 Golang安装和配置 Goland安装 HelloWorld程序解释及Go编码规范 Go语言变量及常量 Go语言运算符 Go语言流程控制——条件语句 Go语言流程控制——循环语句 Go语言函数与指针 Go内置容器_数组和切片 Go内置容器_map与list 字符串处理函数 time及math包及随机数与键盘输入 regexp包及正则表达式的应用 OOP编程 接口 Go语言的文件操作 Go错误处理——error Go异常处理——defer、panic、recover 网络编程——http HTTP状态码 Go语言数据库编程 MySQL数据库安装步骤 MySQL数据库之SQL高级查询 并发编程goroutine 并发编程channel Go加密算法 来源: oschina 链接: https://my.oschina.net/victorfengming/blog/3211220

Automatically import 3rd party go packages

流过昼夜 提交于 2020-03-15 07:30:30
问题 I was wondering if there is a way to automatically download all the imports. So let's assume I need to use github.com/gorilla/mux and several other packages in my code base. Should I manually go to my ~/go/src and run go get repo or is there a smarter way of doing dependency management. I am using Goland IDE for my development. 回答1: if there is a way to automatically download all the imports You can download all imported pkgs and their dependencies by running go get from the command line. I

Automatically import 3rd party go packages

前提是你 提交于 2020-03-15 07:30:09
问题 I was wondering if there is a way to automatically download all the imports. So let's assume I need to use github.com/gorilla/mux and several other packages in my code base. Should I manually go to my ~/go/src and run go get repo or is there a smarter way of doing dependency management. I am using Goland IDE for my development. 回答1: if there is a way to automatically download all the imports You can download all imported pkgs and their dependencies by running go get from the command line. I

升级golang版本导致vscode中golang没有代码提示问题处理

杀马特。学长 韩版系。学妹 提交于 2020-03-02 07:47:32
上半年安装了vscode中golang的插件,经过折腾代码提示这些都好了,但当时goland还可以用,就放弃了vscode来编写golang。下半年go升级1.11,最新版的goland没法用licence server激活了,又把vscode翻出来准备编写golang,发现代码提示只剩下PANIC了。 经过网上查找解决方法,也按照这篇文章修改了vscode 的配置,但依然无法进行代码提示。 参考: https://www.cnblogs.com/Dennis-mi/p/8280552.html { "go.autocompleteUnimportedPackages": true, "go.useCodeSnippetsOnFunctionSuggest": true, "go.gopath": "/home/chensl004/Workspace/go/", "go.useCodeSnippetsOnFunctionSuggestWithoutType": true, "go.inferGopath": true, "go.gotoSymbol.includeImports": true, "go.gotoSymbol.includeGoroot": true, "go.formatTool": "gofmt" } 后来查看vscode在github上的wiki

学习笔记1-goland结构体(struct)

北慕城南 提交于 2020-02-28 19:55:46
写在前面 :若有侵权,请发邮件by.su@qq.com告知。 转载者告知 :如果本文被转载,但凡涉及到侵权相关事宜,转载者需负责。请知悉! 本文永久更新地址: https://my.oschina.net/bysu/blog/3040138 【若要到岸,请摇船:开源中国 不最醉不龟归】 很多年前学习了一下goland,但是没有怎么开始就放下了,这次贴了心学到底。看了一下,觉得goland比较重要的部分就是:1.函数;2.结构体;3.接口;4.并发。 每次要学什么东西之前,我就会狂搜罗一大堆相关的书籍及教程,然后从中挑选一两本或者各教程中某部分来看。这次也不例外,看了很多本关于goland的书,觉得还是 《Go语言从入门到进阶实战》 比较不错,比较适合我这种菜鸡(连菜鸟都不算)的人,并且里面的例子确实挺好的。好了,废话不多说,下面的内容就是看 《Go语言从入门到进阶实战》 这本书接口这部分的笔(抄)记(袭),感兴趣的可以买来学习一下。 --------------------------------------- Go语言通过用户自定义的方式形成新的类型,结构体是类型中带有成员的复合类型。Go语言使用结构体和结构体成员来描述真实世界的实体和实体对应的各种属性。 Go语言中的类型可以被实例化,使用new或“&”构造的类型实例的类型是类型的指针。 结构体成员是由一系列的成员变量构成

GoLand 2020永久激活

廉价感情. 提交于 2020-02-28 03:49:33
注意:本教程补丁来源于 https://zhile.io ,如有侵权请联系作者删除! 本项目只做学习研究之用,不得用于商业用途! 本教程适用于GoLand所有版本 2020.2019.11.29 jetbrains公司发布了Go的最强编辑器GoLand 2019.3。本次更新软件消耗更少的CPU和更快的性能,增强了对Go Modules的支持,添加了一组新的快速修复程序,并增强了重构。可以通过Evaluate Expression调用嵌入式字段的方法,并使用Mozilla rr远程调试应用程序。 一、激活前注意事项 GoLand一定要是在官网下载: https://www.jetbrains.com/goland/download/ 本教程适用于GoLand所有版本 本教程适用于jetbrains全系列产品(Pycharm、Idea、WebStorm、phpstorm、CLion、RubyMine、AppCode、DataGrid) 不需要修改hosts文件,以及任何配置文件 如果按照此教程还无法激活,加猪哥微信拉你进激活群 二、激活教程 1.下载破解补丁 点击链接 https://pan.baidu.com/s/1v4g_fNTZse7piY9aPXNN9g 下载补丁文件 jetbrains-agent.jar (如果链接失效可关注微信公众号「 裸睡的猪 」回复激活群,补丁来源于

这个IM项目没时间搞了,开源算了。10万并发,基于golang。

隐身守侯 提交于 2020-02-26 02:54:35
先上效果 安装方法 本系统升级到golang1.12,请开启如下支持 #开启go mod支持 export GO111MODULE=on #使用代理 export GOPROXY=https://goproxy.io 1.下载项目 git clone https://github.com/winlion/chat.git 2.项目配置 2.1 ide配置 goland IDE ADD Configuration->左上角+->go build类型,右侧填写 files :{你的项目路径}/hellox.x/main.go workdir:{你的项目路径}/hellox.x/ vscode 安装golang插件即可,无需配置,推荐使用 2.2 数据库配置 修改service/init.go 中数据库配置文件 const ( driveName = "mysql" //数据库类型,不要动 dsName = "root:root@(127.0.0.1:3306)/tech-chat?charset=utf8" //tech-chat是数据库名称,请先创建 showSQL = true //是否显示sql语句 maxCon = 10 //最大连接数 NONERROR = "noerror" //一个字符串标记常量 ) 为你自己的数据库以及密码,格式如下 用户名:密码@(ip:port)

Debugger configuration in GoGland

孤街醉人 提交于 2020-01-15 11:43:27
问题 I want to debug my go application when I send request using curl command. Currently my request is handled by the binary I have. What I want that when I send request using curl command request should be handled by the code I have not by the binary. I did not find any documentation about it, only found this thiswhich is still unanswered. @Zoyd did you found a way to configure it? 回答1: I've made a short video of how debugging works in Gogland and how it should be configured: https://youtu.be

Debugger configuration in GoGland

泄露秘密 提交于 2020-01-15 11:42:32
问题 I want to debug my go application when I send request using curl command. Currently my request is handled by the binary I have. What I want that when I send request using curl command request should be handled by the code I have not by the binary. I did not find any documentation about it, only found this thiswhich is still unanswered. @Zoyd did you found a way to configure it? 回答1: I've made a short video of how debugging works in Gogland and how it should be configured: https://youtu.be