skills/organizing-root-files/SKILL.md
Routes root-level markdown files to appropriate directories or deletes obsolete content. Use when project root accumulates analysis files, memos, or documentation needing organization.
npx skillsauth add bacchus-labs/wrangler organizing-root-filesInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
You are the root directory organization specialist. Your job is to identify markdown files that were created at the project root and route them to their appropriate locations based on content and purpose.
Approach:
List all markdown files in project root:
find . -maxdepth 1 -name "*.md" -type f
Filter to organizational candidates:
RCA-*.md (Root cause analyses)ANALYSIS-*.mdIMPLEMENTATION-*.mdSUMMARY-*.mdNOTES-*.mdDESIGN-*.mdINVESTIGATION-*.mdREADME.mdCHANGELOG.mdLICENSE.mdCONTRIBUTING.mdCODE_OF_CONDUCT.mdRead each candidate file:
Output: List of files with preliminary categorization
For each file, determine:
Criteria:
Signs of obsolescence:
Action: Delete file
Criteria:
Signs it's a memo:
Action: Move to memos/ with date-prefixed name
Naming convention:
memos/YYYY-MM-DD-topic-slug.md
Examples:
RCA-AUTH-FAILURE.md → memos/2025-11-17-auth-failure-rca.mdIMPLEMENTATION-SUMMARY-MCP.md → memos/2024-10-29-mcp-integration-summary.mdNOTES-DEBUGGING-SESSION.md → memos/2025-11-15-debugging-session-notes.mdCriteria:
Signs it's user documentation:
Action: Move to docs/ with lowercase-dash-separated name
Naming convention:
docs/lowercase-with-dashes.md
Examples:
USING-WORKFLOWS.md → docs/using-workflows.mdAPI-GUIDE.md → docs/api-guide.mdGETTING-STARTED.md → docs/getting-started.mdCriteria:
Signs it's developer documentation:
Action: Move to devops/docs/ with lowercase-dash-separated name
Naming convention:
devops/docs/lowercase-with-dashes.md
Examples:
DEPLOYMENT-GUIDE.md → devops/docs/deployment-guide.mdARCHITECTURE-DECISIONS.md → devops/docs/architecture-decisions.mdCI-CD-SETUP.md → devops/docs/ci-cd-setup.mdApproach:
Create directories if needed:
mkdir -p memos
mkdir -p devops/docs
# docs/ usually exists, but ensure it
mkdir -p docs
For each file, execute action:
Delete:
rm FILE.md
Move to memos:
# Extract or infer date
mv FILE.md memos/YYYY-MM-DD-topic.md
Move to docs:
# Convert to lowercase-dash format
mv FILE.md docs/lowercase-topic.md
Move to devops/docs:
mv FILE.md devops/docs/lowercase-topic.md
Track all actions for report
Output: Organized file structure
Generate organization report:
# Root Directory Organization Report
## Summary
Organized [N] markdown files from project root.
**Actions:**
- Deleted: [N] obsolete files
- Moved to memos/: [N] files
- Moved to docs/: [N] files
- Moved to devops/docs/: [N] files
## Detailed Actions
### Deleted (Obsolete)
- `RCA-INCORRECT-HYPOTHESIS.md` - Discarded analysis, superseded by correct RCA
- `TEMP-DEBUG-NOTES.md` - Temporary debugging session notes, issue resolved
### Moved to memos/
- `RCA-AUTH-FAILURE.md` → `memos/2025-11-17-auth-failure-rca.md`
- Root cause analysis worth preserving for future reference
- `IMPLEMENTATION-SUMMARY-MCP.md` → `memos/2024-10-29-mcp-integration-summary.md`
- Implementation summary documenting MCP integration decisions
- `INVESTIGATION-PERFORMANCE.md` → `memos/2025-11-10-performance-investigation.md`
- Performance investigation findings and solutions
### Moved to docs/
- `USING-WORKFLOWS.md` → `docs/using-workflows.md`
- User guide for workflow system
- `API-EXAMPLES.md` → `docs/api-examples.md`
- API usage examples for end users
### Moved to devops/docs/
- `DEPLOYMENT-GUIDE.md` → `devops/docs/deployment-guide.md`
- Deployment procedures for maintainers
- `ARCHITECTURE-DECISIONS.md` → `devops/docs/architecture-decisions.md`
- ADR for internal design decisions
## Root Directory Status
**Before:** [N] markdown files (excluding standard files like README.md)
**After:** 0 organizational files remaining
**Preserved at root:**
- README.md
- CHANGELOG.md
- LICENSE.md
[etc.]
## Recommendations
- All analysis/documentation files now properly organized
- Root directory clean and maintainable
- Future files should follow guidelines in CLAUDE.md
---
*Generated by organizing-root-files skill*
Use this decision tree:
Is the file relevant anymore?
Who is the audience?
What's the purpose?
Still unsure?
When moving to memos/, try to determine the date:
Check git history:
git log --follow --format=%aI -- FILE.md | tail -1
Check file modification time:
stat -f %Sm -t %Y-%m-%d FILE.md # macOS
stat -c %y FILE.md | cut -d' ' -f1 # Linux
Check content for date references:
Use today's date if unknown:
Never modify file content - only move and rename.
The goal is organization, not editing.
If truly ambiguous:
Always preserve these at root:
File: RCA-DATABASE-DEADLOCK.md
Content preview:
# Root Cause Analysis: Database Deadlock
## Issue
Production experienced deadlocks on 2024-08-15...
## Investigation
...detailed analysis...
## Solution
Implemented row-level locking instead of table locks...
## Lessons Learned
- Always use row-level locking for high-concurrency tables
- Monitor lock wait times
Decision: MEMOS
Action: Move to memos/2024-08-15-database-deadlock-rca.md
File: DEBUG-NOTES-TEMP.md
Content preview:
# Debug notes
Trying different approaches to fix auth bug...
Approach 1: didn't work
Approach 2: didn't work
Approach 3: FIXED IT! (moved to proper implementation)
Delete this file after confirming fix deployed.
Decision: DELETE
Action: Delete file
File: WORKFLOW-USAGE.md
Content preview:
# Using Wrangler Workflows
This guide shows you how to use workflows in your projects.
## Running Housekeeping
To clean up your project:
```bash
/wrangler:housekeeping
...
**Decision:** DOCS
- Teaching users how to use feature
- No internal details
- End-user focused
**Action:** Move to `docs/workflow-usage.md`
---
### Example 4: Deployment Procedure
**File:** `DEPLOY-PROCESS.md`
**Content preview:**
```markdown
# Deployment Process
## References
For detailed information, see:
- `references/detailed-guide.md` - Complete workflow details, examples, and troubleshooting
tools
Use when creating technical specifications for features, systems, or architectural designs. Creates comprehensive specification documents using the Wrangler MCP issue management system with proper structure and completeness checks.
testing
Creates and refines agent skills using TDD methodology with pressure testing and rationalization detection. Use when creating new skills, editing existing skills, testing skills with pressure scenarios, or verifying skills work before deployment.
tools
Use when design is complete and you need detailed implementation tasks - creates tracked MCP issues with exact file paths, complete code examples, and verification steps. Optional reference plan file for architecture overview.
development
Validates governance file completeness, format compliance, and metric accuracy. Use when auditing governance health, after bulk changes, or ensuring documentation integrity.