restore — Restore skills from lock file

Read .xskill-lock.json from the current directory and install all recorded skills. Useful for setting up a new environment or restoring skills after cloning a project. Skills are grouped by source_url so each repository is cloned only once, avoiding redundant git operations.

xskill restore [OPTIONS]

Options:

  • -g, --global — Install to global ~/.agents/skills/ directory (default: project-level .agents/skills/)
  • -a, --agent <AGENT> — Target platform (use '*' for all platforms)
  • -D, --dry-run — Preview mode: list skills to restore without installing

Install targets

FlagTarget
(none)Project-level .agents/skills/
-gGlobal ~/.agents/skills/
-a <platform>Platform-specific directory (e.g., .claude/skills/)
-a '*'All configured platforms

Examples

# Restore all skills to project
xskill restore

# Restore to global directory
xskill restore --global

# Restore to a specific platform
xskill restore --agent claude

# Preview what would be restored
xskill restore --dry-run

Output format:

Restoring: vue
  Source: https://github.com/antfu/skills.git
  Target: .agents/skills/vue
  Name: Vue
  Description: Vue.js skill pack

Restore complete: 3 succeeded, 0 failed

Dry-run output (grouped by skill name to avoid redundancy):

Skills to restore:

NAME   SOURCE                                      TARGET
vue    https://github.com/antfu/skills.git         .claude/skills/vue
                                                    .codex/skills/vue
react  https://github.com/antfu/skills.git         .claude/skills/react
                                                    .codex/skills/react

Color rules: multi-target (-a '*' or multiple platforms) — table header in blue, continuation TARGET entries in dimmed gray. Single target (-a <name>) — no color.