Skip to content

Plugin Auto-Update Feature #6159

@Davincible

Description

@Davincible

Plugin Auto-Update Feature

Problem

Users currently have no way to stay updated with plugin releases. Plugins are installed once and never updated automatically, requiring manual:

  • Version monitoring
  • Config file updates
  • OpenCode restarts

This leads to outdated plugins with potential security issues, bug fixes, and new features going unused.

Solution

Add automatic plugin update checking and installation with user-controlled policies and notifications.

Key Requirements

Configuration Options:

  • plugin_autoupdate: "disabled" | "notify" | "patch-only" | "auto"
  • plugin_update_check_interval: Update check frequency (default 1h)
  • plugin_update_exclude: Array of plugins to skip

Update Policies:

  • "disabled": No automatic updates (current behavior)
  • "notify": Check and notify of available updates, manual installation
  • "patch-only": Auto-update patch versions only (safest)
  • "auto": Auto-update all versions (requires restart)

User Experience:

  • Background version checking with caching
  • Notifications for available updates regardless of policy
  • CLI commands: opencode plugin check, opencode plugin update
  • Update status indicators and restart notifications

Safety:

  • Automatic rollbacks on update failure
  • Plugin integrity validation
  • Rate limiting for registry API calls

Implementation Approach

  1. Extend config schema with update settings
  2. Add background version checking with caching
  3. Implement update orchestration with rollback capability
  4. Add CLI commands and event notifications
  5. Integrate with existing plugin loading system

I'm happy to work on implementing this feature if the design approach is approved. Let me know your thoughts!

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions