Free, open-source Windows optimization tool for performance, privacy, and simplicity.
C# csharpdebloatdotnetgamingopen-sourceoptimizationoptimizeroptimizerduckperformanceprivacytweakertweakswindowswinui
feat: add rules to AI agents
fatDuck1cfd579771cb
diff --git a/.agents/rules/repository-guidelines.md b/.agents/rules/repository-guidelines.mdnew file mode 100644index 0000000..96c2b53--- /dev/null+++ b/.agents/rules/repository-guidelines.md@@ -0,0 +1,54 @@+---+trigger: always_on+---++# Repository Guidelines++Welcome to the `optimizerDuck` repository! This document provides guidelines for contributing to the project, ensuring consistency and maintainability across the codebase.++## Project Structure & Module Organization++The repository is organized into two primary projects:++- **`optimizerDuck/`**: The core C# Windows application source.+ - `UI/`: Contains XAML views, pages, and components.+ - `Services/`: Houses business logic and system operations (e.g., `DiskCleanupService.cs`, `OptimizationService.cs`).+ - `Common/`: Shared utilities, helpers, and data converters.+ - `Resources/`: Application assets and multi-language `.resx` translation files.+- **`optimizerDuck.Test/`**: The xUnit test suite for validating application logic.++*To build the application, execute the `build.bat` script in the root directory or run `dotnet build optimizerDuck.slnx`.*++## Coding Style & Naming Conventions++This project targets modern .NET (C#) and uses XAML for the frontend presentation.++- **Classes & Methods**: Use `PascalCase` (e.g., `OptimizationService`, `GetSettings()`).+- **Variables & Parameters**: Use `camelCase` (e.g., `availableSpace`, `configData`).+- **Localization**: Avoid hardcoding UI text. Update the `.resx` files located in the `optimizerDuck/Resources/` directory for any new user-facing strings.+- **Linting & Formatting**: Follow standard C# conventions. The project's `.editorconfig` silently suppresses `CA1416` (Platform compatibility) warnings.++## Testing Guidelines++We utilize **xUnit** as our testing framework and `coverlet` for test coverage.++- **Test Placement**: Align test project paths with the main project layout (e.g., tests for `Services/` go into `optimizerDuck.Test/Services/`).+- **Naming Convention**: Suffix your test classes with `Tests` (e.g., `DiskCleanupServiceTests.cs`). Describe the behavior being tested clearly formatted in your test method names.+- **Running Tests**: You can execute the test suite via the .NET CLI:+ ```bash+ dotnet test optimizerDuck.Test/optimizerDuck.Test.csproj+ ```++## Commit & Pull Request Guidelines++We follow the **Conventional Commits** format for our Git workflow. Structure your commit messages using the following prefixes:++- `feat:` for new capabilities (e.g., `feat: add disk cleanup page and its features`).+- `fix:` for bug resolutions (e.g., `fix: use proper color`).+- `refactor:` for restructurings or enhancements (e.g., `refactor: move converters to common`).++**When submitting a Pull Request:**+- Prepend the PR title with the appropriate conventional commit type.+- Ensure all recent changes compile successfully and all tests pass.+- Provide a brief description of the applied modifications. Link any relevant GitHub issues.+- Include a visual screenshot or GIF if your pull request modifies or creates UI elements.diff --git a/AGENTS.md b/AGENTS.mdindex 0281c30..e78cf51 100644--- a/AGENTS.md+++ b/AGENTS.md@@ -1,37 +1,50 @@# Repository Guidelines+Welcome to the `optimizerDuck` repository! This document provides guidelines for contributing to the project, ensuring consistency and maintainability across the codebase.+## Project Structure & Module Organization-This is a WPF app solution rooted at `optimizerDuck-wpf.slnx`. The main app project is `optimizerDuck/`, and the test project is `optimizerDuck.Test/`. Key folders:-- `optimizerDuck/Core/`: core models, interfaces, and optimizers.-- `optimizerDuck/Common/`: shared helpers and extensions.-- `optimizerDuck/Services/`: app services and managers.-- `optimizerDuck/UI/ViewModels/` and `optimizerDuck/UI/Views/`: MVVM UI layer.-- `optimizerDuck/Resources/`: assets and localization (e.g., `Resources/Images`, `Resources/Languages`).--## Build, Test, and Development Commands-Run from the repo root:-- `dotnet restore optimizerDuck-wpf.slnx` — restore NuGet packages.-- `dotnet build optimizerDuck-wpf.slnx -c Release` — build the full solution.-- `dotnet run --project optimizerDuck/optimizerDuck.csproj` — run the WPF app locally.-- `dotnet test optimizerDuck-wpf.slnx` — run all tests (xUnit).++The repository is organized into two primary projects:++- **`optimizerDuck/`**: The core C# Windows application source.+ - `UI/`: Contains XAML views, pages, and components.+ - `Services/`: Houses business logic and system operations (e.g., `DiskCleanupService.cs`, `OptimizationService.cs`).+ - `Common/`: Shared utilities, helpers, and data converters.+ - `Resources/`: Application assets and multi-language `.resx` translation files.+- **`optimizerDuck.Test/`**: The xUnit test suite for validating application logic.++*To build the application, execute the `build.bat` script in the root directory or run `dotnet build optimizerDuck.slnx`.*## Coding Style & Naming Conventions-- Language: C# with nullable reference types enabled (`net10.0-windows`).-- Indentation: 4 spaces for C# and XAML.-- Naming: PascalCase for types/methods, camelCase for locals, `I` prefix for interfaces.-- Architecture: MVVM; keep view logic in ViewModels and UI logic in Views.-- Toolkit: `CommunityToolkit.Mvvm` is used for view models and commands.++This project targets modern .NET (C#) and uses XAML for the frontend presentation.++- **Classes & Methods**: Use `PascalCase` (e.g., `OptimizationService`, `GetSettings()`).+- **Variables & Parameters**: Use `camelCase` (e.g., `availableSpace`, `configData`).+- **Localization**: Avoid hardcoding UI text. Update the `.resx` files located in the `optimizerDuck/Resources/` directory for any new user-facing strings.+- **Linting & Formatting**: Follow standard C# conventions. The project's `.editorconfig` silently suppresses `CA1416` (Platform compatibility) warnings.## Testing Guidelines-- Framework: xUnit (`optimizerDuck.Test/`).-- Naming: use `ClassNameTests` and place tests alongside feature folders (e.g., `optimizerDuck.Test/Services/`).-- Run: `dotnet test optimizerDuck-wpf.slnx`.++We utilize **xUnit** as our testing framework and `coverlet` for test coverage.++- **Test Placement**: Align test project paths with the main project layout (e.g., tests for `Services/` go into `optimizerDuck.Test/Services/`).+- **Naming Convention**: Suffix your test classes with `Tests` (e.g., `DiskCleanupServiceTests.cs`). Describe the behavior being tested clearly formatted in your test method names.+- **Running Tests**: You can execute the test suite via the .NET CLI:+ ```bash+ dotnet test optimizerDuck.Test/optimizerDuck.Test.csproj+ ```## Commit & Pull Request Guidelines-- Recent commits use a short prefix and colon, e.g., `Refactor: Improve registry & service error handling`.-- Keep messages concise and imperative; avoid single-letter messages.-- PRs should include a short summary, linked issue (if any), and screenshots for UI changes.-## Configuration & Safety Notes-- The app targets Windows (`net10.0-windows`) and runs as a WinExe; build on Windows.-- Optimization actions may change system settings; document new apply/revert steps in `Core/` and `Services/`, and surface them in the UI with clear labels.+We follow the **Conventional Commits** format for our Git workflow. Structure your commit messages using the following prefixes:++- `feat:` for new capabilities (e.g., `feat: add disk cleanup page and its features`).+- `fix:` for bug resolutions (e.g., `fix: use proper color`).+- `refactor:` for restructurings or enhancements (e.g., `refactor: move converters to common`).++**When submitting a Pull Request:**+- Prepend the PR title with the appropriate conventional commit type.+- Ensure all recent changes compile successfully and all tests pass.+- Provide a brief description of the applied modifications. Link any relevant GitHub issues.+- Include a visual screenshot or GIF if your pull request modifies or creates UI elements.