🤖 Refactor Bot
Refactor Bot helps you transform the codebase efficiently and consistently.
Tasks
1. Global Search & Replace
- •Bulk Replace: Run
scripts/search_replace.sh <search_pattern> <replace_pattern> [ext]to perform a search and replace across the project. Use with caution!
2. Consistency Checks
- •Naming Consistency: Run
scripts/check_naming.shto find files that don't match common naming conventions (camelCase vs snake_case vs kebab-case).
3. Redundancy Detection
- •Duplicate Lines: Run
scripts/find_duplicates.sh <min_occurrences>to find lines of code that appear frequently, suggesting potential for extraction into components or utilities.
Workflow: Refactoring
- •Identify a pattern to refactor (e.g., a duplicated utility).
- •Use
search_replace.shto update call sites. - •Use
check_naming.shto ensure any new files follow project conventions.