Loading page...Загружаем страницу...正在加载页面...
AtlasRepo

Twelve of thirteen stale docs were kept alive only by each other

说明与用途

使用 mdsweep 工具将大量过时的 Markdown 文件安全地移动到回收站,工具通过文件年龄和引用关系进行分类。

问题

A large number of markdown documentation files in many repos were old and potentially unnecessary, but simple age‑based deletion would risk removing files that were still referenced within the repo.

结果

The tool identified 687 active, 172 stale, and 176 orphan markdown files across 36 repos. Orphan files were safely moved to a trash directory, preserving a manifest for restoration. The approach avoided accidental deletion of referenced files while cleaning up truly unused documentation.

工作流

  • 1. Scan repo for markdown files and collect metadata (age, inbound links).
  • 2. Classify each file: if age <= threshold → active; else if refs > 0 → stale; else → orphan.
  • 3. For orphan files, move them to .mdsweep/trash/<timestamp>/ and record original path in a manifest.
  • 4. Optionally run the tool with --apply to perform the move; otherwise review the report.
  • 5. Use mdsweep undo to restore files if needed.
  • 6. Periodically run the scan to keep the repo tidy.

证据

Across those 36 repos: 687 active, 172 stale, 176 orphan.

来源

Orphans get moved rather than deleted. fs.renameSync puts them in .mdsweep/trash/<timestamp>/ next to a manifest that records every original path.

来源

  • 记录日期: 2026-09-15T22:00:15.187Z