restore

restore is a command for Claude Code from cwakim/claude-plugins. It costs 68 tokens per session (1,945 once invoked), scanned A, original, MIT.

An interactive command for copying saved memory, handoff notes, plans, and configuration from a backup onto the current machine. It can read a GitHub mirror, object storage, a zip file, or an extracted folder.

In plain words
What is it for?
Use it to restore machine state from a backup, compare what would be restored, approve individual conflicts, and copy selected files without writing back to the backup source.
Why use it?
It restores missing or changed files while avoiding deletion of files that exist only locally. A dry run lets you inspect the proposed changes before applying them.

Command for Claude Code

Written for Claude Code: ${CLAUDE_PLUGIN_ROOT} variable. Also seen: reads .claude/ paths; names the AskUserQuestion tool.

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the memory-backup plugin — 5 commands shipped together

Good fit Use it to restore machine state from a backup, compare what would be restored, approve individual conflicts, and copy selected files without writing back to the backup source.

Compare 6 commands from other repositories ↓
Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add cwakim/claude-plugins
Claude Code
/plugin install memory-backup

Made for: Claude Code.

Or install memory-backup, the plugin that ships this one along with the rest of its 5 commands.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for restore

README.md
[![agentmods](https://agentmods.dev/badge/commands/cwakim/claude-plugins/restore/github.svg)](https://agentmods.dev/commands/cwakim/claude-plugins/restore)
Your own site
<a href="https://agentmods.dev/commands/cwakim/claude-plugins/restore"><img src="https://agentmods.dev/badge/commands/cwakim/claude-plugins/restore/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for restore

Your own site · 80×15
<a href="https://agentmods.dev/commands/cwakim/claude-plugins/restore"><img src="https://agentmods.dev/badge/commands/cwakim/claude-plugins/restore.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 68 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,945 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00068 $0.01945
Opus 5.5 $0.00027 $0.00778
Sonnet 5.5 $0.00014 $0.00389
Haiku 4.5 $0.00007 $0.00194

Measured 1mo ago against content hash 4db1b5a65ff9, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

restore scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/memory-backup/commands/restore.md · 131 lines

How it starts

The opening of the file, as written. The whole thing — 131 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Restore (restore [--dry-run] [path])

Copies from a backup source back onto this machine. Interactive and conservative: it adds and (only with consent) overwrites, and it never deletes anything that exists only locally. Whichever source resolves below, restore only ever reads from it: it never writes back to the source, and never pushes anywhere. With --dry-run it goes exactly as far as the plan (step 3) and stops: nothing is applied, no question is asked, and any temp extraction directory is cleaned up. Useful for checking what a restore would do, especially against the GitHub mirror, which may be weeks ahead of or behind this machine.

The mirror tree and the name-to-target derivation rules live in ${CLAUDE_PLUGIN_ROOT}/docs/layout.md; read it before building the plan. To converge this machine with a different machine's mirror, use merge (${CLAUDE_PLUGIN_ROOT}/commands/merge.md) instead: restore maps a mirror back onto the machine it came from (or a replacement for it), merge reconciles two machines' divergent state.

Resolve the source

  • <path> given: a zip made by zip <path>, or its already-extracted folder. If <path> is a file (a .zip), extract it into a fresh temp directory (mktemp -d) and use that as the source root; if it is already a directory, use it directly. Verify the source root contains at least one machines/<hostname>/ subtree; if not, say so and stop. No GitHub involved at all: no clone, no gh, no network, and no need for /backup setup to have ever run.
  • <path> is a gist URL (https://gist.github.com/...): a share bundle made by share (${CLAUDE_PLUGIN_ROOT}/commands/share.md). Fetch it with gh gist view <id> --raw (or --files), read the bundle.zip.base64 file, base64-decode it to a temp .zip, extract that into a fresh temp directory (mktemp -d), and use it as the source root exactly like a local zip. Requires gh authenticated; no /backup setup needed. The gist's ONBOARDING.md is context for a human, not part of the restore; mention it in the report so the user reads it. A share bundle carries no config/ and only the thread's curated stores, so the plan will naturally be narrow; that is expected.
  • No <path>: a configured backup target. Two kinds can be configured, and both may be at once (see docs/object-storage.md):
    • GitHub mirror (~/.claude/memory-backup/ is a clone with an origin). If it is not configured, this is probably the disaster-recovery path: ask for the backup repo (owner/name), verify it exists, and clone it into place first. Otherwise git pull --ff-only so the mirror is current. The source root is the clone.
    • Object storage (~/.claude/memory-backup-obstore.json exists). Read bucket/prefix/endpoint/region/profile from it and materialize the mirror into a fresh temp directory (mktemp -d) with ${CLAUDE_PLUGIN_ROOT}/scripts/obstore-pull.sh --dest <tmp> --bucket .... That temp directory is then the source root, handled exactly like an extracted zip: read-only, and cleaned up at the end (step 4) or on any early stop, since this run created it.
    • Both configured: ask via AskUserQuestion which to restore from (they can differ: the bucket may be ahead of or behind the git mirror). Only one configured: use it without asking.

Read the full file on GitHub · 131 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago Changed · +13 lines · +4 tokens per session 4db1b5a65ff9
  2. 1mo ago First seen · 118 lines · 64 tokens per session scan A f59cea8b7e6f

Subscribe to this mod's changes

restore is a command published in the GitHub repository cwakim/claude-plugins (2 stars, last pushed 23d ago), licensed MIT. It adds 68 tokens to every session and 1,945 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.