Drop a dependency from project.json and optionally delete its cached jar.
pluggy remove [options] <plugin>
pluggy rm [options] <plugin>
<plugin> is the dependency key in project.json:dependencies. For Modrinth it's the slug. For Maven it's the artifactId. For file deps it's the basename without .jar. For workspace deps it's the sibling name.
| Flag | Default | Notes |
|---|---|---|
--keep-file |
off | Don't delete the cached jar. |
--workspace <names> |
none | Target a specific workspace. |
--workspaces |
off | Remove from every workspace that declares it. |
A plugin is removed from one workspace, so --workspace takes exactly one name even though it parses the shared repeatable grammar. Naming two fails with E_WORKSPACE_NOT_SINGLE.
At a multi-workspace root you must pass one of --workspace or --workspaces. remove refuses to guess. Running a bare pluggy remove foo at the root errors:
error: remove: at the workspace root, pass --workspace <name> or --workspaces to disambiguate
Contrast with install, which defaults to all workspaces when ambiguous. remove is irreversible, so the default is "explicit or nothing."
- Reads every targeted
project.json, drops the entry, and writes the file back with a trailing LF. - Reads
pluggy.lock. If the entry is still declared by a workspace that wasn't targeted, it shrinksdeclaredByand stops there. Otherwise it deletes the lockfile entry entirely. - Unless
--keep-file, best-effort-unlinks the cached jar (~/Library/Caches/pluggy/dependencies/<kind>/.../<version>.jar).
Your own source jars (the file:./libs/foo.jar on disk) are never touched. Only the content-addressed cache copy is deleted.
workspace: entries are in the lockfile but have no cached jar. fileRemoved stays false even after a successful remove.
Identical to install, with one difference:
at a multi-workspace root, remove requires an explicit flag where
install would default to all workspaces.
$ pluggy remove worldedit
✓ Removed worldedit from my_plugin (and pluggy.lock)
$ pluggy remove --workspaces adventure-api
✓ Removed adventure-api from api, impl (and pluggy.lock)
$ pluggy remove notinstalled
"notinstalled" was not declared in the targeted workspaces; nothing to do.
{
"status": "success",
"removed": ["my_plugin"],
"lockEntryRemoved": true,
"fileRemoved": true
}| Trigger | Message |
|---|---|
Missing <plugin> |
remove: plugin name is required |
| Targeting a specific workspace that doesn't declare the dep | remove: "<plugin>" is not declared in <workspace> (<path>) |
| Cached jar exists but can't be unlinked | Warning on stderr: remove: could not delete <path>: <errno>. Command still succeeds. |
When --workspaces is set and the dep isn't present in some workspaces, those are listed in the JSON missing field (human mode shows a count only).
pluggy install: the counterpart.pluggy list: audit what's currently declared.- Dependencies: lockfile shape.