-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Problem
When a page moves from one section to another (e.g., /docs/intro.md to /docs/getting-started/intro.md):
- The new file is created ✓
- The old file is NOT automatically deleted ✗
- The cache accumulates both paths in
outputPaths
Current Behavior
Stale files remain on disk after pages are reorganized, causing:
- Disk space accumulation
- Potential duplicate content in builds
- Manual cleanup required
Example Scenario
- Page
intro.mdinitially outputs tobuild/intro.html - Page moves sections, now outputs to
build/getting-started/intro.html - Old file
build/intro.htmlremains on disk - Cache now tracks both paths
Potential Fix
Add logic to detect when a page's expected path differs from all cached paths, and clean up the old files. This could involve:
- Tracking the 'current' vs 'stale' output paths
- Implementing a cleanup routine during cache invalidation
- Detecting orphaned files during build time
Related
Related to cache path normalization and detection improvements
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels