Skip to content

feat(cli): add plugin disable/enable commands - #12490

Closed
scarf005 wants to merge 1 commit into
anomalyco:devfrom
scarf005:feat/7687/cli-disable-plugins
Closed

scarf005 wants to merge 1 commit into
anomalyco:devfrom
scarf005:feat/7687/cli-disable-plugins

Conversation

@scarf005

@scarf005 scarf005 commented Feb 6, 2026 •

Copy link
Copy Markdown
Contributor

Summary

add CLI commands to list,enable or disable plugins without editing config file

Changes

  • Added disabled_plugins field to config schema
  • Modified plugin loading to filter out disabled plugins
  • Added new CLI commands:
    • opencode plugin list - list all plugins and their status
    • opencode plugin disable <name> - disable a plugin
    • opencode plugin enable <name> - enable a previously disabled plugin

Usage

# List all plugins and their status
opencode plugin list

# Disable a plugin
opencode plugin disable my-plugin

# Enable a previously disabled plugin
opencode plugin enable my-plugin

Related Issues

Resolves #7687

@github-actions

github-actions Bot commented Feb 6, 2026

Copy link
Copy Markdown
Contributor

The following comment was made by an LLM, it may be inaccurate:

I found a related PR that could be a potential duplicate:

Related PR Found:

This PR appears to address very similar functionality - adding plugin management CLI commands. It shows up in multiple searches related to plugin management. Given that PR #12490 is specifically adding plugin disable/enable commands, there's a possibility this was previously attempted or partially implemented in PR #7611. You may want to check if #7611 was closed/merged and whether this PR is building on that work or duplicating it.

@scarf005
scarf005 force-pushed the feat/7687/cli-disable-plugins branch from a010ffa to 445f5c5 Compare February 6, 2026 15:42
Add new CLI commands to manage plugins:
- opencode plugin list - list all plugins and their status
- opencode plugin disable <name> - disable a plugin
- opencode plugin enable <name> - enable a previously disabled plugin

Also adds disabled_plugins config field to track disabled plugins
without removing them from the config.

Resolves anomalyco#7687
@scarf005
scarf005 force-pushed the feat/7687/cli-disable-plugins branch from 445f5c5 to c9235e5 Compare February 15, 2026 17:19
@old-mikser

Copy link
Copy Markdown

Can this, or related PRs be merged?

@TheAnig

TheAnig commented Feb 24, 2026

Copy link
Copy Markdown

+1 can this be merged?

@ndizazzo

Copy link
Copy Markdown

A great use case for getting this merged is that Oh My Opencode overrides the available agents in my project. I sometimes want to run without OmO for a clean environment - having a quick CLI switch + option to do this would really help instead of needing to edit the JSON config

@TheAnig

TheAnig commented Feb 28, 2026

Copy link
Copy Markdown

A great use case for getting this merged is that Oh My Opencode overrides the available agents in my project. I sometimes want to run without OmO for a clean environment - having a quick CLI switch + option to do this would really help instead of needing to edit the JSON config

This is the exact same situation I'm in and my motivation behind seeing this merged

@AIR-hl

AIR-hl commented Mar 7, 2026

Copy link
Copy Markdown

+1 can this be merged?

@buithehien1991

Copy link
Copy Markdown

+1

@domeniczz

Copy link
Copy Markdown

please please please merge this pull request, this feature is sooooooooo good

@json9512

Copy link
Copy Markdown

I've setup a quick plugin to manage the plugins 😄
I know its counter intuitive, but couldn't wait for this PR to merge.
(I do think opencode should natively support this though)

to anyone interested, here it is.

you can use slash commands to enable/disable plugins
/opm enable oh-my-opencode -> restart opencode
/opm disable oh-my-opencode -> restart opencode

@crd2333

crd2333 commented Mar 31, 2026

Copy link
Copy Markdown

+1

@nightknighto

Copy link
Copy Markdown

zzz

@thdxr

thdxr commented Oct 10, 2026

Copy link
Copy Markdown
Member

This branch has been upgraded to V2. We're no longer taking PRs for V1. If you think this is still relevant, please port it over and open it for V2.

— from 𝕺𝖕𝖊𝖓𝕮𝖔𝖉𝖊

@thdxr thdxr closed this Oct 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE]: Disable plugins via cli