Repomix Unmixer

Use when extracting files from a repomix-packed repository (XML/Markdown/JSON) to restore the original directory structure — reverses the repomix packing process.

aashutosh396 Updated

File contents

Repomix Unmixer

Extract files from a repomix-packed file and restore the original directory tree.

Workflow

python3 scripts/unmix_repomix.py "<repomix_file>" "<output_dir>"

Parses the format, extracts each file path + content, recreates dirs, writes files, reports count.

Supported formats

  • XML (default): <file path="...">content</file> blocks (regex matched).
  • Markdown: ## File: path followed by fenced code block.
  • JSON: {"files":[{"path":...,"content":...}]}.

Principles

  • Always specify an output dir — never dump into cwd.
  • Extract to /tmp first for review, then tree it, spot-check content, then move to final dest.
  • Never extract directly over important dirs — verify before overwriting (use a fresh dir or output-$(date +%s)).
  • For skills: validate after unmixing with skill-creator tools.

Troubleshooting

  • No files extracted → wrong/unsupported format; inspect file manually.
  • Permission error → mkdir -p + writable dir, or use $HOME/extracted.
  • Garbled chars → script is UTF-8; check source encoding.
  • Path exists → fresh output dir or clear it first.

aashutosh396/mindpalace commit e4d20ea523

Frequently asked questions

npx get-skill add aashutosh396/repomix-unmixer