nocobase-plugin-manage
Installation
SKILL.md
Goal
Provide a deterministic plugin workflow using only direct nb pm commands:
nb pm listnb pm enablenb pm disable
This skill must not route plugin operations through wrapper scripts or fallback channels.
Scope
- Inspect plugin inventory/state from CLI runtime (
nb pm list). - Enable plugins with
nb pm enable <plugin>. - Disable plugins with
nb pm disable <plugin>. - Always perform readback with
nb pm listafter writes.
Non-Goals
- Do not use
docker compose exec ... yarn nocobase pm .... - Do not use API action routes (
pm:list,pm:enable,pm:disable) as fallback. - Do not use legacy ctl commands or wrapper scripts for plugin operations.
- Do not support
install/removein this skill version.
Input Contract
| Input | Required | Default | Validation | Clarification Question |
|---|---|---|---|---|
action |
yes | none | one of inspect/enable/disable |
"Which action should I run: inspect, enable, or disable?" |
plugins |
enable/disable: yes | none | non-empty string array | "Which plugin(s) should be changed?" |
base_dir |
no | current working directory | existing path | "Which directory should nb commands run in?" |
execution_mode |
no | safe |
one of safe/fast |
"Use safe mode or fast mode?" |
verify.timeout_seconds |
no | 90 |
integer 10..600 |
"What verification timeout should I use?" |
Rules:
- Keep compact invocation:
Use $nocobase-plugin-manage <action> [plugin...]. safemode requires pre-state + post-state readback.- If user says "you decide", use defaults above.
Mandatory Clarification Gate
- Max clarification rounds:
2 - Max questions per round:
3 - Before
enable/disable,pluginsmust be resolved. - If required inputs are missing, stop mutation and ask.
Workflow
- Parse request and normalize to
inspect/enable/disable. - Capture pre-state via
nb pm listwhenexecution_mode=safe. - Execute action with direct command:
inspect:nb pm listenable:nb pm enable <plugin>disable:nb pm disable <plugin>
- Readback polling via
nb pm listuntil timeout. - Return structured output.
Safety Gate
- High-impact actions:
- disable auth/ACL/system-critical plugins
- batch disable in shared environments
- Secondary confirmation template:
- "Confirm execution:
{{action}}for{{plugins}}. Typeconfirmto continue." - Rollback guidance:
- failed disable: run
nb pm enable <plugin> - failed enable: run
nb pm disable <plugin>(only when user requests rollback)
Verification Checklist
actionandpluginsresolved.- Command path uses direct
nb pmonly. - Pre-state captured in
safemode. - Post-state readback captured.
enable=> plugin showsenabled=true.disable=> plugin showsenabled=false.- Timeout reported as
pending_verification.
Minimal Test Scenarios
inspectusesnb pm list.enableusesnb pm enablethen readback bynb pm list.disableusesnb pm disablethen readback bynb pm list.- Missing plugin input blocks mutation with clarification.
Output Contract
Always return:
requestcommandspre_statepost_stateverification(passed|failed|pending_verification)assumptionsnext_steps