返回顶部
l

local-file-manager

Read, write, append, and list local files in the session's working directory. Use when you need to persist output to disk, read input files, or manipulate file system safely. Supports text files, JSON, CSV, Markdown.

作者: admin | 来源: ClawHub
源自
ClawHub
版本
V 1.0.0
安全检测
已通过
584
下载量
0
收藏
概述
安装方式
版本历史

local-file-manager

# Local File Manager Skill This skill provides safe file I/O operations within the session's `cwd`. It is designed for roles that need to store outputs locally (no cloud sync). ## Capabilities - **Read file**: Get contents of a text file - **Write file**: Create or overwrite a file - **Append file**: Add content to existing file - **List files**: Directory listing with filtering - **Delete file**: Remove a file (with safety checks) - **Copy/Move**: Simple file operations ## When to Use Role needs to: - Save generated code/analysis to disk - Read input documents (PDFs, text, etc.) - Append logs or results - Create output files in Markdown/JSON/CSV ## Usage ```bash # Read a file file-manager --action read --path output.md # Write content (from stdin or --content) file-manager --action write --path result.json --content '{"status":"done"}' # Append to file file-manager --action append --path log.txt --content "Job completed at $(date)" # List files in directory file-manager --action list --dir . --pattern "*.md" # Create directory file-manager --action mkdir --dir reports # Delete file (with confirmation) file-manager --action delete --path old_file.txt ``` ## Safety - **Sandboxed to cwd**: Cannot access files outside session's working directory - **Protected files**: Cannot delete files starting with `.` or in `../` - **Size limit**: Max file size 10MB (configurable) - **Dry-run support**: `--dry-run` shows what would happen ## Integration with Roles In role config, enable this skill: ```yaml plugins: allow: - local-file-manager - doc-parser ``` Then in the role's system prompt, guide usage: ``` When you finish analysis, write the result to a file: file-manager --action write --path summary.md --content "$YOUR_MARKDOWN" ``` ## Examples **Researcher saving analysis:** ```bash file-manager --action write --path analysis_$(date +%Y%m%d).md \ --content "# Analysis\n\n## Summary\n..." ``` **Developer saving code:** ```bash file-manager --action write --path src/main.py --content "$CODE" ``` **Automation appending log:** ```bash file-manager --action append --path /var/log/automation.log \ --content "[$(date)] Task completed\n" ``` ## Error Handling - If file doesn't exist for read: returns error code 1 - If path is outside cwd: denied - If write fails (permission): returns error - All errors logged to `~/.openclaw/logs/file-manager.log` ## Configuration Environment variables: - `FILE_MANAGER_MAX_SIZE`: Max file size in bytes (default 10485760) - `FILE_MANAGER_LOG`: Path to operation log (default `~/.openclaw/logs/file-manager.log`) - `FILE_MANAGER_DRY_RUN`: Set to "1" to only simulate operations

标签

skill ai

通过对话安装

该技能支持在以下平台通过对话安装:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 local-file-manager-1776000542 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 local-file-manager-1776000542 技能

通过命令行安装

skillhub install local-file-manager-1776000542

下载 Zip 包

⬇ 下载 local-file-manager v1.0.0

文件大小: 5.16 KB | 发布时间: 2026-4-13 10:53

v1.0.0 最新 2026-4-13 10:53
Local skill registration

Archiver·手机版·闲社网·闲社论坛·羊毛社区· 多链控股集团有限公司 · 苏ICP备2025199260号-1

Powered by Discuz! X5.0   © 2024-2025 闲社网·线报更新论坛·羊毛分享社区·http://xianshe.com

p2p_official_large
返回顶部