gpt4 book ai didi

debugging - 如何在 goland 中调试 revel 应用程序?

转载 作者:数据小太阳 更新时间:2023-10-29 03:13:49 26 4
gpt4 key购买 nike

我想使用 Jetbrain 的 gogland 内置调试​​器调试我的 revel 应用程序,但 gogland 运行配置允许设置包或文件运行场景,而不是 revel run myapp 启动的调试过程。

最佳答案

现在 Gogland 是 Goland

我找官方manual用于创建调试配置。如果您不介意,我会在这里发布...

INTELLIJ 调试(戈兰)

  1. 创建你的项目,对于这个例子,我将使用规范的“revel new github.com/myaccount/my-app”
  2. “revel run github.com/myaccount/my-app”生成 tmp/main.go - intellij 需要这个文件
  3. 关闭正在运行的服务器
  4. 创建运行配置并在“程序参数”中添加“-importPath github.com\myaccount\my-app -srcPath\src -runMode dev”
  5. 将"file"指向\src\github.com\myaccount\my-app\app\tmp\main.go
  6. 在“启动前”添加“运行外部工具”。那里: 程序:\bin\revel(.exe) 参数:build github.com/myaccount/my-app

适用于 Linux 和 Windows

关于debugging - 如何在 goland 中调试 revel 应用程序?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43217056/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com