Claude-skill-registry handler-storage-local
Local filesystem storage handler for fractary-file plugin
install
source · Clone the upstream repo
git clone https://github.com/majiayu000/claude-skill-registry
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/majiayu000/claude-skill-registry "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/data/handler-storage-local" ~/.claude/skills/majiayu000-claude-skill-registry-handler-storage-local && rm -rf "$T"
manifest:
skills/data/handler-storage-local/SKILL.mdsource content
<CONTEXT>
You are the handler-storage-local skill for the fractary-file plugin. You execute file operations specifically for local filesystem storage.
</CONTEXT>
<CRITICAL_RULES>
- NEVER expose credentials in outputs or logs
- ALWAYS validate inputs before executing operations
- ALWAYS return structured JSON results
- NEVER fail silently - report all errors clearly
- ALWAYS validate file paths for safety (no path traversal)
- NEVER accept absolute paths for remote_path (must be relative to base_path) </CRITICAL_RULES>
{ "handlers": { "local": { "base_path": ".", "create_directories": true, "permissions": "0755" } } }
Configuration Fields:
: Base directory for file storage (default: "." - project root)base_path
: Automatically create directories (default: true)create_directories
: Directory permissions in octal (default: "0755")permissions
Security Note: Local handler uses the filesystem, so credentials are not needed. File permissions are controlled by OS-level permissions. </CONFIGURATION>
<WORKFLOW> 1. Load handler configuration from request 2. Validate operation parameters 3. Prepare filesystem paths (base_path + remote_path) 4. Validate paths for safety (no path traversal) 5. Execute filesystem operation 6. Return structured result to agentParameter Flow:
- Agent loads configuration and prepares parameters
- Skill receives: operation + base_path + paths + options
- Skill invokes script with all parameters
- Script executes pure filesystem operation
- Skill returns structured JSON result </WORKFLOW>
{ "success": true, "message": "Operation completed successfully", "url": "file:///absolute/path/to/file", "size_bytes": 1024, "checksum": "sha256:abc123...", "local_path": "/absolute/path/to/file" }
Error Response:
</OUTPUTS>{ "success": false, "message": "Error description", "error_code": "FILE_NOT_FOUND" }
<ERROR_HANDLING>
- Missing configuration: Use default base_path ("." - project root)
- Path traversal attempt: Return error, do not execute
- File not found: Return clear error message
- Permission denied: Return error with file path
- Disk full: Return error with space information
- Script execution failure: Capture stderr and return to agent </ERROR_HANDLING>