Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>GoLand OpenerNew to Visual Studio Code? Get it now.
GoLand Opener

GoLand Opener

cursor-goland-opener

|
124 installs
| (0) | Free
在 GoLand 中打开当前文件并定位到光标位置,支持 Git Submodule 自动同步
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

GoLand Opener

一个 Cursor 编辑器插件,提供以下核心功能:

  • 在 GoLand 中打开当前文件并定位到光标位置
  • Git Submodule 自动同步

功能特性

在 GoLand 中打开当前文件

  • 使用快捷键(默认 Ctrl+Alt+G)快速在 GoLand 中打开当前文件
  • 自动定位到 Cursor 中光标所在的行和列
  • 支持自定义 GoLand 安装路径
  • 支持 Windows、macOS 和 Linux

Git Submodule 自动同步

  • 自动同步 Git Submodule
  • 可配置同步时间间隔(1-60分钟)

使用方法

在 GoLand 中打开文件

  1. 在 Cursor 中打开任意文件
  2. 按下快捷键 Ctrl+Alt+G(Windows/Linux)或 Cmd+Alt+G(macOS)

Git Submodule 自动同步

  1. Cursor 打开的项目,可自动同步 git submodule

配置指南

配置方式

编辑 settings.json

  1. 打开命令面板(Ctrl+Shift+P)
  2. 输入并选择 "Preferences: Open Settings (JSON)"
  3. 添加配置项

配置示例

{
    "goland-opener.golandPath": "C:\\Program Files\\JetBrains\\GoLand 2024.3.3\\bin\\goland64.exe",
    "goland-opener.keyboardShortcut": "ctrl+alt+g",
    "goland-opener.gitSubmodule.autoSync": true,
    "goland-opener.gitSubmodule.syncInterval": 1,
    "goland-opener.gitSubmodule.showInStatusBar": true
}

选项说明

  • goland-opener.golandPath (string)

    • GoLand 可执行文件的完整路径
    • 默认值:系统标准安装路径
      • Windows: C:\Program Files\JetBrains\GoLand 2024.3.3\bin\goland64.exe
      • macOS: /Applications/GoLand.app/Contents/MacOS/goland
      • Linux: /opt/goland/bin/goland.sh
  • goland-opener.keyboardShortcut (string, 默认: ctrl+alt+g)

    • 打开 GoLand 的快捷键
    • macOS 用户使用 cmd 替代 ctrl
  • goland-opener.gitSubmodule.autoSync (boolean, 默认: true)

    • 启用 Git Submodule 自动同步
  • goland-opener.gitSubmodule.syncInterval (number, 默认: 1)

    • 自动同步间隔(分钟),范围 1-60
  • goland-opener.gitSubmodule.showInStatusBar (boolean, 默认: true)

    • 在状态栏显示同步状态

常见问题

找不到 GoLand

  • 检查 GoLand 安装路径是否正确
  • Windows 路径使用双反斜杠 \\ 或单正斜杠 /
  • 确保有权限访问 GoLand 可执行文件

快捷键不生效

  • 检查是否与其他插件的快捷键冲突
  • 重新加载 Cursor 编辑器
  • 确认当前窗口有焦点

Git Submodule 同步问题

  • 确保项目根目录存在 .gitmodules 文件
  • 检查是否有网络连接和 Git 访问权限
  • 查看 Cursor 输出面板中的错误信息

注意事项

  1. 修改任何配置后,需要重新加载 Cursor 编辑器
  2. 确保配置的路径指向 GoLand 的可执行文件(.exe/.sh)
  3. Git Submodule 自动同步需要项目中存在 .gitmodules 文件
  4. 自动同步可能会产生网络流量,在移动网络环境下请谨慎使用

开发者指南

如果你想参与开发或构建此插件,请查看 开发指南。

许可证

MIT

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft