ubx terminate tears down a deployed stack. It checks for a prior apply record (from ubx ship) to reuse the compiled artifact. If no record exists, it runs the full compile pipeline first.
Usage
Flags
| Flag | Description |
|---|---|
--force | Skip the confirmation prompt |
Examples
What happens
- Check apply record — reads
.ubx/last-apply.json- If found: reuses the
artifact_uriandplugin_name(skips compile) - If not found: runs the full XCL pipeline (compile → typecheck → IR → plugin Compile)
- If found: reuses the
- Confirmation — prompts with resource count unless
--force - Plugin Destroy — invokes plugin’s
DestroyRPC, streams progress events
Progress output
Safety
Without--force, ubx shows:
y to proceed. Any other input cancels.
After termination
The apply record (.ubx/last-apply.json) is not automatically removed. Run ubx state list to verify the stack is empty.
Exit codes
| Code | Meaning |
|---|---|
0 | All resources destroyed |
1 | Compile/typecheck/destroy error; user cancelled |

