Add plugin auto-build and hot reload for dev#4
Open
Diddyy wants to merge 1 commit intonitrodevco:mainfrom
Open
Add plugin auto-build and hot reload for dev#4Diddyy wants to merge 1 commit intonitrodevco:mainfrom
Diddyy wants to merge 1 commit intonitrodevco:mainfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds development-only plugin hot reload and auto-build capabilities to improve the plugin development workflow when debugging Turbo.Main. The changes introduce file system watchers that monitor plugin artifacts and source code, automatically rebuilding and reloading plugins when changes are detected. These features are only enabled in the Development environment via configuration.
Changes:
- Added
ReloadAsync(string key)method to PluginManager for targeted single-plugin reloads - Implemented PluginHotReloadService to watch plugin artifact folders and trigger reloads on file changes
- Implemented PluginAutoBuildService to watch plugin source folders and trigger dotnet builds on code changes
- Wired up console commands
reload-pluginsandreload-plugin <key>for manual plugin management
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 13 comments.
Show a summary per file
| File | Description |
|---|---|
| Turbo.Plugins/PluginManager.cs | Added ReloadAsync method for single-plugin reloads and extracted RebuildDependents helper |
| Turbo.Plugins/PluginHotReloadService.cs | New hosted service that watches plugin artifacts and debounces reload requests |
| Turbo.Plugins/PluginAutoBuildService.cs | New hosted service that watches plugin source files and triggers auto-builds |
| Turbo.Plugins/Extensions/ServiceCollectionExtensions.cs | Conditionally registers hot reload and auto-build services in Development environment |
| Turbo.Plugins/Configuration/PluginConfig.cs | Added configuration properties for hot reload and auto-build features |
| Turbo.Main/Console/ConsoleCommandService.cs | Implemented reload-plugins and reload-plugin commands with proper usage messages |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
4506f48 to
faa9095
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds DevPluginPaths config so the emulator loads plugins directly from their build output directory — no more copying DLLs into plugins/ during development.
Dev workflow:
Changes: