Roo-Code/src/core
Yu SERIZAWA 580672ffc8
feat: enhance rule file loading with .roo/rules directory support (#2354)
* feat: enhance rule file loading with .roo/rules directory support

- Introduced functions to safely read files and check for directory existence.
- Added capability to read all text files from a specified directory in alphabetical order.
- Updated `loadRuleFiles` to prioritize loading rules from a `.roo/rules/` directory, falling back to existing rule files if necessary.
- Enhanced `addCustomInstructions` to support loading mode-specific rules from a `.roo/rules-{mode}/` directory, improving flexibility in rule management.

This change improves the organization and retrieval of rule files, allowing for better modularity and maintainability.

* Updated strings and translations

* Add tests

* Revert changes to system prompt translations

* Fix path resolution

* Make instruction structure clearer

---------

Co-authored-by: Matt Rubens <mrubens@users.noreply.github.com>
2025-04-07 11:46:30 -04:00
..
__tests__ Refactor: Improve file tool context formatting and diff error guidance (#2278) 2025-04-04 18:26:25 -04:00
assistant-message feat(browserTool): Implement resize action (#2370) 2025-04-07 09:34:32 -04:00
config Add profile management functions to API (#2251) 2025-04-03 01:40:07 -04:00
diff Refactor: Improve file tool context formatting and diff error guidance (#2278) 2025-04-04 18:26:25 -04:00
ignore Add support for a .rooignore file 2025-03-05 10:17:43 -05:00
mentions Revert "feat @-mention window path style & file with space (#1924)" (#2162) 2025-03-31 15:56:47 -05:00
prompts feat: enhance rule file loading with .roo/rules directory support (#2354) 2025-04-07 11:46:30 -04:00
sliding-window Relax provider profiles schema and log parse error to PostHog (#2139) 2025-03-30 23:07:34 -07:00
tools feat(browserTool): Implement hover action (#2368) 2025-04-07 09:35:14 -04:00
webview Tidy up following ClineProvider refactor (#2182) 2025-04-05 18:00:23 -04:00
Cline.ts feat: add workspace tracking to history items (#2054) 2025-04-05 08:23:10 -04:00
CodeActionProvider.ts feat: prioritize "Add to Context" and add line number tracking (#2063) 2025-03-28 12:01:16 -04:00
EditorUtils.ts feat: prioritize "Add to Context" and add line number tracking (#2063) 2025-03-28 12:01:16 -04:00
mode-validator.ts Automatically generate roo-code.d.ts (including type generation via zod-to-ts) (#2024) 2025-03-27 09:38:56 -07:00