在LiteIDE中查看Golang包的源代码

时间:2014-06-12 09:42:20

标签: go revel liteide

在LiteIDE中查看golang软件包源代码的最简单方法是什么?

例如,当存在这样的代码时:

import "github.com/revel/revel"

func init() {
    // Filters is the default set of global filters.
    revel.Filters = []revel.Filter{
        revel.PanicFilter,             // Recover from panics and display an error page instead.
        revel.RouterFilter,            // Use the routing table to select the right Action
        revel.FilterConfiguringFilter, // A hook for adding or removing per-Action filters.
        revel.ParamsFilter,            // Parse parameters into Controller.Params.
        revel.SessionFilter,           // Restore and write the session cookie.
        revel.FlashFilter,             // Restore and write the flash cookie.
        revel.ValidationFilter,        // Restore kept validation errors and save new ones from cookie.
        revel.I18nFilter,              // Resolve the requested language
        HeaderFilter,                  // Add some security based headers
        revel.InterceptorFilter,       // Run interceptors around the action.
        revel.CompressFilter,          // Compress the result.
        revel.ActionInvoker,           // Invoke the action.
    }
}

如果我想知道什么是revel.PanicFilter,我会访问http://github.com/revel/revel并寻找源代码..

使用C ++(QtCreator)时,我只需要按住ctrl +然后它就会访问声明/实现。

我的Jump to declaration菜单在LiteIDE中不起作用,可能是因为这些包是在.a存档中压缩的?

file pkg/linux_amd64/github.com/revel/revel.a 
pkg/linux_amd64/github.com/revel/revel.a: current ar archive

是否有更简单的方法来查看源代码,就像在QtCreator中一样?

2 个答案:

答案 0 :(得分:5)

F2 键跳转到 Lite IDE v24.3中的库函数声明

答案 1 :(得分:1)

Ctrl + Shift + J适用于LiteIDE 26. F2不起作用!