Archive Orphaned Attachments

Scan markdown and canvas files to archive unreferenced attachments.

49|12|Updated Jan 8, 2026
One-click install
npx skills add https://github.com/DavidROliverBA/ArchitectKB --skill archive-orphaned-attachments
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Archive Orphaned Attachments
Source: https://github.com/DavidROliverBA/ArchitectKB/tree/main/.claude/skills/archive-attachments
Command: npx skills add https://github.com/DavidROliverBA/ArchitectKB --skill archive-orphaned-attachments

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill identifies and archives attachments within your vault that are no longer linked to any notes, thereby reducing clutter and storage space.

Core Features & Use Cases

  • Orphaned File Detection: Scans all markdown and canvas files to find attachments in the Attachments/ directory that have no references.
  • Automated Archiving: Moves identified orphaned files to an Archive/Attachments/ directory, preserving the original folder structure.
  • Manifest Tracking: Updates an archive-manifest.json file to log all archiving operations.
  • Use Case: Run this skill quarterly to maintain a clean and efficient vault, especially after large data imports or migrations.

Quick Start

Run the archive attachments skill with the dry-run flag to see what would be archived.

Frequently Asked Questions about Archive Orphaned Attachments

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I find and clean up orphaned attachments in my vault?

This Skill detects orphaned attachments by scanning markdown and canvas files for references to files in the Attachments directory, identifying any files with no links pointing to them.

What is the best way to safely archive unreferenced vault files before deleting them?

The dry-run execution mode previews exactly which unreferenced files will be moved to the Archive directory, allowing you to verify safety before permanently altering your vault structure.

How does vault maintenance handle orphaned files after large data imports?

Vault maintenance handles orphaned files by moving them to an Archive directory, preserving the original folder structure, and logging every operation in an archive-manifest.json file for tracking.

Does the attachment archiving script work with both markdown and canvas files?

Yes, the archiving script scans both markdown and canvas files to detect references to files located in the Attachments directory, ensuring accurate orphaned file detection.

Can I preview what files will be archived before moving them?

Yes, you can preview what files will be archived by running the Python script with the dry-run flag, which simulates the archiving process without moving any files.