360 Secure SkillHub
360 安全技能中心

smart-files

基于 Node 的工作区文件工具:可搜索文件名与文本内容、查看文件元数据、归类、检测重复与清理候选并生成统计报告,预览字面重命名,并以前台监控将路径与哈希写入日志;命令不移动或删除文件,扫描范围限定在工作区内。

分类:效率
jlacroix82
jlacroix82
热度 71.09
最近更新 2026-12-02 07:50:35

安装

发给 Agent
帮我安装这个技能:npx secure-skills-cli add jlacroix82/smart-files
兼容性
通用兼容
联网要求
不联网
数据出网
数据不出本机
Metadata
name
smart-files
description
Search, inspect, categorize, and detect duplicate files inside the workspace; preview literal renames or monitor changes.
version
2.2.4
metadata
{"openclaw":{"requires":{"bins":["node"]},"envVars":[{"name":"SMART_FILES_WORKSPACE","required":false,"description":"Operator-selected workspace."}]}}

Smart Files

Use node {baseDir}/smart-files.js only for an explicitly requested part of the workspace. SMART_FILES_WORKSPACE is an operator setting; --dir <path> narrows the scan without expanding the workspace. Symlinks and other linked file paths cannot expand access. --force does not bypass this boundary.

  • --search <query> [--dir <path>] [--snippets] [--quiet]: search names and bounded text content. Snippets are off by default; turn them on only if approved for display. --quiet suppresses snippets.
  • --info <file>: inspect metadata and detect type.
  • --dedup, --organize, --cleanup, --status: report duplicate groups, categories, cleanup candidates, or workspace statistics. These commands do not move or delete files.
  • --rename <file> <old>:<new>: preview a literal filename substitution without renaming.
  • --watch <directory> [interval-seconds]: monitor in the foreground. This saves paths, hashes, and up to 1,000 change records to memory/smart-files-journal.json; it does not save file contents. Only start it on request.

Version 2.2.4 applies workspace checks across modes, bounds watch hashing, and uses literal rename matching.