-
Notifications
You must be signed in to change notification settings - Fork 3.3k
feat: add plugins command to command dialog #5507
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: dev
Are you sure you want to change the base?
Conversation
adaf760 to
d6981ae
Compare
- Add 'List plugins' command to Ctrl+P dialog - Opens modal showing all enabled plugins with versions - Uses sync.data.config for synchronous access
d6981ae to
2f34eb9
Compare
…n highlighting, fix API call
- Fix Config.update to write to opencode.jsonc/opencode.json instead of config.json This ensures config changes persist between sessions since the loader reads opencode.jsonc/opencode.json, not config.json - Fix plugin loading to respect disabled_plugins array Plugins in disabled_plugins are now properly filtered out and not loaded Fixes issue where plugin enable/disable changes were not persisting between sessions and disabled plugins were still being loaded.
|
do you think it's better to have it's own section instead of in status? |
Config.update now uses Filesystem.findUp to find existing config files using the same logic as config loading. This ensures we write to the same file that will be loaded on the next session, fixing persistence issues when config files exist in parent directories.
- Fix mergeConfigWithPlugins to merge disabled_plugins arrays (union) instead of replacing - Simplify Config.update() to write update directly to file, clear cache, and reload - Update server endpoint to return actual merged config result - Ensure changes persist between sessions by properly clearing state cache This fixes the issue where plugin enable/disable changes were not persisting between restarts. The key was ensuring we write to file, clear cache, and reload the full merged config state.
Use reconcile() when updating the config in the sync store to ensure deep reactive updates trigger the enabledPlugins memo to recompute, providing immediate visual feedback when toggling plugins in the UI.
Add a note in the plugins dialog indicating that changes require a restart to take effect, making it clearer to users that the UI state reflects the config state (what will be after restart) rather than the currently running plugins.
When updating plugin config, we should REPLACE the arrays, not merge/concatenate them. The merge logic is for loading configs from multiple sources, not for updates. This fixes the issue where enabling plugins wasn't persisting correctly because the arrays were being concatenated instead of replaced.
wdym by this, I just couldn't see them anywhere else and was bugging me out discoverability wise I'd also like to be able to enable/disable from the app not just config files |
|
Also no discussions for RFC but would be nice to try to give more power to plugins like be able to hook on the ui wise and maybe some way to install them easily from a repo like opencode plugin install owner/repo or such lmk where would be a good place to discuss these! |
|
what i mean is we have the /status command and im wondering if showing the plugins there would make more sense |
Add 'List plugins' command to the Ctrl+P command dialog.