From popcorn
Export site files from a Popcorn channel into the local project. USER-TRIGGERED ONLY — never invoke pre-emptively. For general export, use the CLI directly (popcorn site export).
How this skill is triggered — by the user, by Claude, or both
Slash command
/popcorn:exportThis skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
Downloads the latest (or a specific version of) site files from a Popcorn channel into the local project. The inverse of `/popcorn:pop`.
Downloads the latest (or a specific version of) site files from a Popcorn channel into the local project. The inverse of /popcorn:pop.
This command should "just work" — resolve the channel, handle safety checks, and extract files automatically.
bash "${CLAUDE_PLUGIN_ROOT}/skills/popcorn/setup.sh"
The last line is JSON: {"cli":true/false,"auth":true/false,"mcp":true/false}.
cli and auth are both true → proceed.Same resolution logic as /popcorn:pop:
A #channel-name or bare name after /export → use it directly.
POPCORN_AGENT=1 popcorn site targets
If there's a default target, use it. Tell the user: "Exporting from #<site_name>."
If multiple targets, list them and ask which one.
Tell the user: "No linked channel found. Provide a channel name (e.g. #my-app), or run /popcorn:pop first to link a channel."
From the user's free-form text (everything after /export), infer:
#channel-name or bare nameExamples:
/popcorn:export → default target, latest version
/popcorn:export #my-app → pull from #my-app
/popcorn:export v3 → default target, version 3
/popcorn:export #my-app v3 → pull from #my-app, version 3
/popcorn:export the version before dark mode → ask user to clarify version
Check for uncommitted changes:
git status --porcelain 2>/dev/null
If there are uncommitted changes, warn the user: "You have uncommitted changes. The export will back up current files to .popcorn-backup/. Continue?" If they decline, stop. If they confirm, proceed with --force.
If no uncommitted changes or not a git repo, proceed normally.
POPCORN_AGENT=1 popcorn site export '#<channel-name>' [--version VERSION] --force
Parse the response envelope:
{"ok": true, "data": {"version": 5, "commit_hash": "abc123", "backup": ".popcorn-backup"}}{"ok": false, "error": "..."} on stderr<site_name> v<version> into the project. Backup at .popcorn-backup/."git status --short or git diff --stat to show the user what files were added/modified.popcorn site export --revert."Creates, edits, and optimizes skills for Claude Code, including drafting, evaluating with test prompts, iterating on performance, and improving skill descriptions for better triggering accuracy.
npx claudepluginhub popcornaihq/popcorn-claude-code --plugin popcorn