file-browser
VerifiedRead-only file browsing and reading in the OpenClaw workspace (/home/alfred/.openclaw/workspace). Use for listing directories or reading text files (up to 10...
$ Add to .claude/skills/ About This Skill
# File Browser Skill
Quick Start Resolve all paths relative to WORKSPACE=/home/alfred/.openclaw/workspace. Sanitize inputs to prevent escapes or absolutes.
- To list directory: exec("scripts/list_files.sh", [rel_path]) → JSON {success: bool, data: array of names, error: string}
- To read file: exec("scripts/read_file.sh", [rel_path]) → JSON {success: bool, data: string (text content), error: string}
- Handle errors: For binary/large/non-text files, return error JSON.
Step-by-Step Workflow 1. Parse user query for action (list/read) and relative path. 2. Call appropriate script with sanitized rel_path. 3. Parse JSON output; respond to user with results or error message. 4. If path invalid or outside workspace, reject immediately.
Safety Guidelines - Enforce read-only: No writes, deletes, or exec beyond scripts. - Log accesses if verbose mode enabled. - For large files (>10k chars), truncate or summarize.
Edge Cases - Empty path: Default to "." (workspace root). - Binary file: Return error "Non-text file". - See references/examples.md for more (if added).
Bundled Resources - scripts/list_files.sh: Bash wrapper for ls. - scripts/read_file.sh: Bash wrapper for cat with limits.
Use Cases
- Browse and navigate directory structures through an interactive file explorer
- View file previews and metadata without opening files in an editor
- Search for files by name, extension, or content across directory trees
- Manage files and directories: copy, move, rename, and delete operations
- Navigate large codebases quickly with tree view and filtering
Pros & Cons
Pros
- +Interactive navigation is more intuitive than raw ls and cd commands
- +File preview eliminates the need to open files just to check content
- +Search and filter capabilities speed up file discovery in large projects
Cons
- -Browser-based approach adds overhead compared to direct terminal commands
- -Only available on claude-code and openclaw platforms
- -Feature set may overlap with the IDE's built-in file explorer
FAQ
What does file-browser do?
Read-only file browsing and reading in the OpenClaw workspace (/home/alfred/.openclaw/workspace). Use for listing directories or reading text files (up to 10...
What platforms support file-browser?
file-browser is available on Claude Code, OpenClaw.
What are the use cases for file-browser?
Browse and navigate directory structures through an interactive file explorer. View file previews and metadata without opening files in an editor. Search for files by name, extension, or content across directory trees.
100+ free AI tools
Writing, PDF, image, and developer tools — all in your browser.