Debugging with Sublime & goSublime

agolangf · · 940 次点击    
这是一个分享于 的资源,其中的信息可能已经有所发展或是发生改变。
<p>I&#39;m starting with Golang and using Sublime 3 and goSublime. However, I still haven&#39;t found out how to debug, set breakpoints, etc.</p> <p>Can anyone shed some light on this? Thanks!</p> <hr/>**评论:**<br/><br/>FIuffyRabbit: <pre><p>Because go doesn&#39;t have an official debugger. </p></pre>patrickdappollonio: <pre><p>Unfortunately, Go doesn&#39;t have an official debugger. I know Visual Studio Code (free) has a good Go plugin with support for Delve which allows you to set breakpoints and inspect stuff. I don&#39;t know if you can couple Delve with Sublime Text + GoSublime. </p></pre>PaluMacil: <pre><p>As far as I&#39;m aware, you&#39;re correct about it not having the step debugging that VS Code has. Personally I am very pleased with the lightness of VS Code and quality of debugging in a lot of languages where it can get complex (Go, TypeScript, C#, etc). The editor is faster than Atom due to technical choices and code quality, and while it comes with some limits on customization that Atom allows and not as much speed as Sublime, it feels the best put together, organized, and well thought out. Your only other choice for simple step debugging would be Gogland by JetBrains.</p></pre>frr149: <pre><p>The only problem is that I just paid for Sublime. O:-)</p> <p>Isn&#39;t there any way of using Delve with Sublime?</p></pre>patrickdappollonio: <pre><p>Manually... I don&#39;t know if I&#39;m remembering correctly (and I&#39;m on mobile) but you should be able to put breakpoints as code in your code and then run delve and from within delve run your app. The code breakpoints will make delve stop and debug at that location. But again, I don&#39;t remember if it was that way and mobile doesn&#39;t make it easier to Google it...

入群交流(和以上内容无关):加入Go大咖交流群,或添加微信:liuxiaoyan-s 备注:入群;或加QQ群:692541889

940 次点击  
加入收藏 微博
暂无回复
添加一条新回复 (您需要 登录 后才能回复 没有账号 ?)
  • 请尽量让自己的回复能够对别人有帮助
  • 支持 Markdown 格式, **粗体**、~~删除线~~、`单行代码`
  • 支持 @ 本站用户;支持表情(输入 : 提示),见 Emoji cheat sheet
  • 图片支持拖拽、截图粘贴等方式上传