From code
Dynamically locates files in Claude Code plugins cache (~/.claude/plugins/cache), auto-resolving latest versions. Useful for slash commands and orchestrators finding tools, skills, or resources without hardcoding paths.
npx claudepluginhub closedloop-ai/claude-plugins --plugin codeThis skill uses the workspace's default tool permissions.
This skill provides a utility to dynamically locate files within the Claude Code plugins cache directory. Instead of hardcoding paths like `.claude/tools/python`, use this skill to find files in `~/.claude/plugins/cache/closedloop-ai/` with automatic latest-version resolution.
Guides Next.js Cache Components and Partial Prerendering (PPR) with cacheComponents enabled. Implements 'use cache', cacheLife(), cacheTag(), revalidateTag(), static/dynamic optimization, and cache debugging.
Guides building MCP servers enabling LLMs to interact with external services via tools. Covers best practices, TypeScript/Node (MCP SDK), Python (FastMCP).
Generates original PNG/PDF visual art via design philosophy manifestos for posters, graphics, and static designs on user request.
This skill provides a utility to dynamically locate files within the Claude Code plugins cache directory. Instead of hardcoding paths like .claude/tools/python, use this skill to find files in ~/.claude/plugins/cache/closedloop-ai/ with automatic latest-version resolution.
To find a file in the plugins cache, run the find_plugin_file.py script:
python scripts/find_plugin_file.py <file_pattern>
# Find parse_args.py in any plugin (returns first match)
python scripts/find_plugin_file.py parse_args.py
# Find all SKILL.md files across all plugins
python scripts/find_plugin_file.py SKILL.md --all
# Find a specific file using path pattern
python scripts/find_plugin_file.py plan/parse_args.py
# Find tools in a specific subdirectory
python scripts/find_plugin_file.py tools/python/plan/parse_args.py
# Search only in code plugin
python scripts/find_plugin_file.py parse_args.py --plugin code
python scripts/find_plugin_file.py --list-plugins
To use in a slash command that needs to reference plugin tools, use a two-step approach:
# Step 1: Locate the find_plugin_file.py script (handles multiple plugin versions)
FIND_SCRIPT=`ls ~/.claude/plugins/cache/closedloop-ai/code/*/skills/find-plugin-file/scripts/find_plugin_file.py 2>/dev/null | sort -V | tail -1`
# Step 2: Use the script to find the target file, then derive TOOLS_PATH
TARGET_FILE=`python "$FIND_SCRIPT" plan/parse_args.py`
TOOLS_PATH=`dirname \`dirname "$TARGET_FILE"\``
# Step 3: Run with correct PYTHONPATH
PYTHONPATH="$TOOLS_PATH:$PYTHONPATH" python "$TARGET_FILE" --help
Important:
`) instead of $() for command substitution — Claude Code's Bash tool escapes $() syntax.code/*/skills/... can match multiple version directories. Always use ls ... | sort -V | tail -1 to select the latest version.| Argument | Description |
|---|---|
file_pattern | File name or path pattern to find |
--plugin, -p | Restrict search to a specific plugin |
--all, -a | Return all matches instead of just the first |
--list-plugins, -l | List available plugins and their latest versions |
--cache-dir | Override the default cache directory |
The script automatically selects the latest version of each plugin using semantic versioning comparison. For example, if a plugin has versions 1.6.0, 1.9.1, and 1.10.0, it will search in 1.10.0.
find_plugin_file.py - Main utility script for locating files in the plugins cache