Skip to content
Back to skills

Open Nvim

ASecurity

用 open-nvim 在运行中的 Neovim 实例打开文件并精确跳转行列;多文件时填入 quickfix 并打开面板。仅在用户主动键入 /open-nvim 时调用,不要自动触发

  • 5 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added September 4, 2026
toolsbashnode

Security analysis

A100/100

Scanned November 9, 2026

npx -y skills add beixiyo/dotfiles --skill open-nvim --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Open Nvim?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Open Nvim
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/beixiyo-open-nvim/badge)](https://www.skillsdirectory.com/skills/beixiyo-open-nvim)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: open-nvim
description: 用 open-nvim 在运行中的 Neovim 实例打开文件并精确跳转行列;多文件时填入 quickfix 并打开面板。仅在用户主动键入 /open-nvim 时调用,不要自动触发
---

调用 `~/.local/bin/open-nvim` 把文件在运行中的 Neovim 实例里打开,并精确跳转到指定行列;多文件时填入 quickfix 并打开面板。所有参数同一格式,可传任意多个:

```bash
~/.local/bin/open-nvim src/foo.ts:42:7          # 单文件:行列可缺省,默认 1:1
~/.local/bin/open-nvim a.ts:10 b.lua:5:2 c.md   # 多文件:同一文件可出现多次
```

## 执行步骤

1. 从用户的消息里解析出文件路径列表,以及每项可选的行号、列号
2. 用 Bash 执行,将命令的 stdout/stderr 原样回显给用户
3. 若脚本输出 `No running Neovim instance found`,告知用户当前没有活跃的 Neovim 实例

## 注意

- 文件路径若为相对路径,保持原样传入,脚本内部会用 `realpath` 解析
- 列号按 UTF-16 码元计(含中文等多字节字符的行与浏览器/编辑器字符列一致),不是字节列;不确定时省略列号

## 网页调用

手动启动本机服务:

```bash
node ~/.claude/skills/open-nvim/scripts/server.mjs
```

服务监听所有网卡(IPv4 和 IPv6),依次尝试端口 `43123` 到 `43132`,启动时打印实际端口。下面示例使用默认端口;若端口冲突,请替换成启动输出中的实际端口

也可以指定固定端口(被占用时直接报错):

```bash
OPEN_NVIM_PORT=43200 node ~/.claude/skills/open-nvim/scripts/server.mjs
```

```bash
curl -G 'http://127.0.0.1:43123/open-nvim' \
  --data-urlencode 'file=/绝对路径/文件' \
  --data-urlencode 'line=42' --data-urlencode 'column=1'

# 也支持 POST,字段与 GET 一致
curl -X POST 'http://127.0.0.1:43123/open-nvim' \
  -H 'Content-Type: application/json' \
  --data '{"file":"/绝对路径/文件","line":42,"column":1}'
```

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in tools →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.