← 返回 Skills 市场
wanng-ide

Json Linter

作者 WANGJUNJIE · GitHub ↗ · v1.0.0
cross-platform ✓ 安全检测通过
826
总下载
1
收藏
1
当前安装
1
版本数
在 OpenClaw 中安装
/install json-linter
功能描述
Validates JSON syntax across the workspace. Use this skill to check for syntax errors in configuration files, memory files, or data assets.
使用说明 (SKILL.md)

JSON Linter

A simple utility to recursively scan the workspace for .json files and validate their syntax using JSON.parse().

Usage

# Scan the entire workspace (from current working directory)
node skills/json-linter/index.js

# Scan a specific directory
node skills/json-linter/index.js --dir path/to/dir

Output

JSON report containing:

  • scanned_at: Timestamp
  • total_files: Number of .json files scanned
  • valid_files: Number of valid files
  • invalid_files: Number of invalid files
  • errors: Array of error objects:
    • path: Relative path to file
    • error: Error message (e.g., "Unexpected token } in JSON at position 42")

Example Output

{
  "scanned_at": "2026-02-14T21:45:00.000Z",
  "total_files": 150,
  "valid_files": 149,
  "invalid_files": 1,
  "errors": [
    {
      "path": "config/broken.json",
      "error": "Unexpected token } in JSON at position 42"
    }
  ]
}
安全使用建议
This skill appears to do exactly what it says: recursively read .json files and report syntax errors. Before installing or running it, consider: 1) it will read any .json files in the workspace (so it can see JSON-formatted secrets/configs); 2) the bundled code runs under node — review index.js and scripts/test.js yourself or run them in a sandbox/container if you are unsure; 3) there is no network activity in the code, and no external downloads are performed, which reduces risk; 4) if you want to avoid scanning some paths, the script only skips a few hard-coded names (node_modules, .git, temp, logs) — adjust or run it against an explicit directory to limit scope. If you need higher assurance, run the test suite (node scripts/test.js) in an isolated environment first.
功能分析
Type: OpenClaw Skill Name: json-linter Version: 1.0.0 The skill bundle provides a JSON linter that recursively scans a specified directory for `.json` files and validates their syntax. The `index.js` script uses standard Node.js file system operations (`fs.readdirSync`, `fs.readFileSync`) and `JSON.parse()` for validation. It correctly handles command-line arguments for the target directory using `path.resolve` and passes them directly to `fs` functions, preventing shell injection. There are no external dependencies, network calls, data exfiltration attempts, or prompt injection instructions in `SKILL.md`. The `scripts/test.js` file is a benign unit test. All files align with the stated purpose without exhibiting any malicious intent or significant vulnerabilities.
能力评估
Purpose & Capability
Name and description match the delivered code: index.js and SKILL.md implement a recursive workspace scan for .json files and validate them with JSON.parse(). No extra binaries, env vars, or unrelated capabilities are requested.
Instruction Scope
SKILL.md instructs running the included Node script to scan a directory. The implementation reads filesystem directories and files, parses JSON, and emits a report. It does not access the network, other processes, or system credentials. It will read any .json files in the workspace (which is expected for this purpose).
Install Mechanism
There is no install spec or external download; this is essentially an instruction-only skill with bundled scripts. package.json declares no dependencies. Risk from installation is minimal because nothing is fetched from remote sources.
Credentials
The skill declares no required environment variables or credentials and the code does not read env vars. Note: because it scans the workspace, it can read any JSON files present — including files that may contain secrets (e.g., credentials stored as JSON). This access is coherent with the skill's purpose but is something the user should be aware of.
Persistence & Privilege
Flags are default (always: false). The skill does not modify other skills or global agent configuration. It can be invoked autonomously by the agent (platform default), but that is not a unique privilege for this skill.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install json-linter
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /json-linter 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
Initial release of json-linter. - Scans `.json` files recursively in the workspace or a specified directory. - Validates JSON syntax using `JSON.parse()`. - Generates a JSON summary report including scan time, file counts, and error details for invalid files.
元数据
Slug json-linter
版本 1.0.0
许可证
累计安装 1
当前安装数 1
历史版本数 1
常见问题

Json Linter 是什么?

Validates JSON syntax across the workspace. Use this skill to check for syntax errors in configuration files, memory files, or data assets. 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 826 次。

如何安装 Json Linter?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install json-linter」即可一键安装,无需额外配置。

Json Linter 是免费的吗?

是的,Json Linter 完全免费(开源免费),可自由下载、安装和使用。

Json Linter 支持哪些平台?

Json Linter 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 Json Linter?

由 WANGJUNJIE(@wanng-ide)开发并维护,当前版本 v1.0.0。

💬 留言讨论