ctx-plan-import
Import Claude Code plan files into project specs. Use when plan files in ~/.claude/plans/ should become permanent project specs.
Best use case
ctx-plan-import is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Import Claude Code plan files into project specs. Use when plan files in ~/.claude/plans/ should become permanent project specs.
Teams using ctx-plan-import should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/ctx-plan-import/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How ctx-plan-import Compares
| Feature / Agent | ctx-plan-import | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Import Claude Code plan files into project specs. Use when plan files in ~/.claude/plans/ should become permanent project specs.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
Import Claude Code plan files (`~/.claude/plans/*.md`) into the
project's `specs/` directory so they become part of project memory.
## When to Use
- User says "import plans", "save that plan", "keep the plan"
- User wants to preserve a Claude Code plan as a project spec
- After a planning session produced a plan worth keeping
- User asks to review or archive recent plans
## When NOT to Use
- User wants to create a new spec from scratch (use `/ctx-spec`)
- User wants to edit an existing spec directly
- No `~/.claude/plans/` directory or it's empty
## Process
### 1. Discover Plans
List plan files with modification dates:
```bash
ls -lt ~/.claude/plans/*.md 2>/dev/null
```
If no files are found, tell the user and stop.
### 2. Filter by Arguments
The user may pass arguments to narrow the selection:
| Argument | Behavior |
|----------------------|--------------------------------------------------------|
| `--today` | Only plans modified today |
| `--since YYYY-MM-DD` | Only plans modified on or after the given date |
| `--all` | Import all plans without prompting |
| *(none)* | Interactive: present the list and ask the user to pick |
**Filtering with `--today`:**
```bash
find ~/.claude/plans/ -name '*.md' -newermt "$(date +%Y-%m-%d)" -type f
```
**Filtering with `--since`:**
```bash
find ~/.claude/plans/ -name '*.md' -newermt "YYYY-MM-DD" -type f
```
### 3. Present for Selection (Interactive Mode)
For each plan file, extract the first H1 heading and show it with
the modification date:
```
1. 2026-02-28 Add authentication middleware
2. 2026-02-27 Refactor database connection pool
3. 2026-02-25 Import plans skill
```
Ask the user which plans to import (comma-separated numbers, or "all").
### 4. Import Each Selected Plan
For each selected plan:
1. **Read the file** to extract the H1 heading (first `# ` line)
2. **Slugify the heading** for the filename:
- Lowercase
- Replace spaces and non-alphanumeric characters with hyphens
- Collapse multiple hyphens
- Trim leading/trailing hyphens
- Example: `Add Authentication Middleware` → `add-authentication-middleware`
3. **Check for conflicts**: if `specs/{slug}.md` already exists, ask
the user whether to overwrite or pick a different name
4. **Copy the file** to `specs/{slug}.md`
5. **Optionally add a task**: ask the user if they want a task in
TASKS.md referencing the imported spec (use `/ctx-task-add` if yes)
### 5. Report
After importing, summarize what was done:
```
Imported 2 plan(s):
~/.claude/plans/abc123.md → specs/add-authentication-middleware.md
~/.claude/plans/def456.md → specs/refactor-database-pool.md
```
## Important Notes
- Plan filenames in `~/.claude/plans/` are typically UUIDs or hashes:
always use the H1 heading for the spec filename, not the original name
- If a plan has no H1 heading, use the original filename (minus extension)
as the slug
- Do not modify the original plan files: this is a copy, not a move
- The `specs/` directory must exist (it should already be present in
the project root)Related Skills
ctx-import-plans
Import plan files into project specs directory. Use to convert external plans into project-tracked specs.
ctx-plan
Stress-test a plan through adversarial interview. Find what's weak, missing, or unexamined before the user commits. Use when the user wants their plan scrutinized.
ctx-verify
Verify before claiming completion. Use before saying work is done, tests pass, or builds succeed.
ctx-skill-creator
Create, improve, test, and deploy skills. Full skill lifecycle from intent to working skill file.
ctx-sanitize-permissions
Audit tool permissions for dangerous or overly broad entries. Use to ensure safe agent configuration.
ctx-recall
Browse session history. Use when referencing past discussions or finding context from previous work.
ctx-prompt
Apply, list, and manage saved prompt templates from .context/prompts/. Use when the user asks to apply, list, or create a reusable template like code-review or refactor.
ctx-journal-normalize
Normalize journal source markdown for clean rendering. Use after journal site shows rendering issues: fence nesting, metadata formatting, broken lists.
ctx-compact
Archive completed tasks and trim context. Use when context files are growing large.
ctx-check-links
Audit docs for dead links. Use before releases, after restructuring docs, or when running a documentation audit.
ctx-add-task
Add a task. Use when follow-up work is identified or when breaking down complex work into subtasks.
ctx-add-learning
Record a learning. Use when discovering gotchas, bugs, or unexpected behavior that future sessions should know about.