agentsclimarketplace

Clain plan recreate

Skill drai-inn/clain/skills/clain-plan-recreate

Tidy up workspace sprawl from AI-assisted coding — categorical classification + executable plans for dev workspaces piling up under Google Drive sync.

Install
npx -y skills add drai-inn/clain --skill clain-plan-recreate

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 1 stars1 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its author says it does

Copied from the file, not written here

Use when the developer wants a delete-and-recreate plan for cache-managed / ephemeral / bytecode subtrees of their dev workspaces — e.g. "show me a recreate plan", "what would clain delete and rebuild?", "plan to wipe node_modules and reinstall via pnpm". Always runs in --dry mode; never executes deletions. Surfaces unsafe actions (ambiguous toolchain, missing lockfile) prominently so the developer can review before any execution is enabled.

SKILL.md

3.3 KB, as published. Nobody here has run it

Run the clain CLI to produce a delete-and-recreate plan in dry mode for a developer-supplied root, then render the result.

Steps

  1. Pick the mode (matches the classify mode the developer used). Single-workspace: pass --here. Tree of workspaces: omit it.

  2. Ensure a classify cache exists. If the developer has not run clain classify (or clain classify --here) for the path recently, do that first (or invoke the clain-classify skill). Without a matching cache, clain plan recreate exits non-zero with a clear error.

  3. Always pass --dry. This is the safe-preview mode and is required for normal use until the project's development-phase gate is lifted by a future named spec.

clain plan recreate --here "$WORKSPACE_PATH" --dry      # single-workspace mode
clain plan recreate "$ROOT" --dry                       # tree mode
  1. Or for machine-readable output:
clain plan recreate --here "$WORKSPACE_PATH" --dry --json
clain plan recreate "$ROOT" --dry --json

For copy-paste into a spreadsheet, use --table (mutually exclusive with --json):

clain plan recreate --here "$WORKSPACE_PATH" --dry --table

The default render groups actions by workspace into Rich panels with the workspace path shown once in the panel title (targets and commands relative to that path); the --table render is a single flat table with absolute paths.

  1. Surface the plan to the developer with these emphases:

    • The total action count and the unsafe count (look for Unsafe: in the footer or summary.unsafe_count in JSON).
    • Any actions flagged with safe_to_execute: false — list them, with their unsafe_reason, before any safe actions.
    • The plan path under $XDG_STATE_HOME/clain/plans/recreate-<UTC>.json. The plan is the audit artefact; tell the developer where it lives.
  2. If the developer asks "can you just run it for me?", explain that execution is blocked by the project's development-phase gate. The plan is the deliverable; the developer reviews it and runs the commands themselves until the gate is lifted by a future spec.

Notes

  • Never omit --dry when invoking this skill. Without it, the command attempts execution, hits the phase gate, and emits an error.
  • Unsafe actions cover real cases: a Python workspace with pyproject.toml but no toolchain lockfile, a Node workspace with package.json but no lockfile, a workspace with no recognised manifest at all. Treat each as a request for developer judgement, not a flaw in the tool.
  • If the command fails (clain: command not found, no classify cache, root does not exist), report the failure verbatim. Do not work around it; do not invent a recreate command from your own knowledge.

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.