renamle plug to plugin command

This commit is contained in:
Sebastian Herrlinger
2026-03-26 23:43:14 +01:00
parent 23ebfa0aee
commit b9d741fb37
3 changed files with 9 additions and 9 deletions

View File

@@ -7,7 +7,7 @@ Technical reference for the current TUI plugin system.
- TUI plugin config lives in `tui.json`.
- Author package entrypoint is `@opencode-ai/plugin/tui`.
- Internal plugins load inside the CLI app the same way external TUI plugins do.
- Package plugins can be installed with `opencode plug <module>`.
- Package plugins can be installed with `opencode plugin <module>`.
## TUI config
@@ -103,8 +103,8 @@ Example:
}
```
- `opencode plug <module>` resolves and installs the package first, then reads `oc-plugin`, then patches config.
- Alias: `opencode plugin <module>`.
- `opencode plugin <module>` resolves and installs the package first, then reads `oc-plugin`, then patches config.
- Alias: `opencode plug <module>`.
- `-g` / `--global` writes into the global config dir.
- Local installs write into `<git worktree>/.opencode` when inside a git repo, otherwise `<cwd>/.opencode`.
- Without `--force`, an already-configured npm package name is a no-op.
@@ -180,7 +180,7 @@ Command behavior:
- `ui.dialog` exposes the host dialog stack:
- `replace(render, onClose?)`
- `clear()`
- `setSize("medium" | "large")`
- `setSize("medium" | "large" | "xlarge")`
- readonly `size`, `depth`, `open`
### Keybinds

View File

@@ -307,9 +307,9 @@ export function createPlugTask(input: PlugInput, dep: PlugDeps = defaultPlugDeps
}
}
export const PlugCommand = cmd({
command: "plug <module>",
aliases: ["plugin"],
export const PluginCommand = cmd({
command: "plugin <module>",
aliases: ["plug"],
describe: "install plugin and update config",
builder: (yargs: Argv) => {
return yargs

View File

@@ -34,7 +34,7 @@ import { Global } from "./global"
import { JsonMigration } from "./storage/json-migration"
import { Database } from "./storage/db"
import { errorMessage } from "./util/error"
import { PlugCommand } from "./cli/cmd/plug"
import { PluginCommand } from "./cli/cmd/plug"
process.on("unhandledRejection", (e) => {
Log.Default.error("rejection", {
@@ -153,7 +153,7 @@ const cli = yargs(hideBin(process.argv))
.command(GithubCommand)
.command(PrCommand)
.command(SessionCommand)
.command(PlugCommand)
.command(PluginCommand)
.command(DbCommand)
.fail((msg, err) => {
if (