prependPlugins
settings.json型
string[]記述場所ユーザー設定または管理者設定ユーザーがインストールしたすべての mod の前に、指定した順序で、管理対象プラグインの mod を実行させるためのリスト。このキーを managed settings で設定する場合、組み込みのガードを維持するにはリストに sec-default@builtin を指定する。managed settings では、そのプラグインが組織のものとみなされない id は Claude Code がスキップする。その条件と、2 つの順序付けキーがどう連携するかについては、Install your organization's mods and set the order を参照。
記述例
{
"extraKnownMarketplaces": {
"acme-tools": {
"source": { "source": "directory", "path": "/opt/acme/claude-plugins" }
}
},
"enabledPlugins": { "acme-guard@acme-tools": true },
"prependPlugins": ["acme-guard@acme-tools", "sec-default@builtin"]
}使い方・用途
- 組織が配布する mod をユーザーが追加する mod より前に実行させ、イベントをユーザーの mod より先に検査・変更・拒否したい場合に使う。
- 管理設定で
prependPluginsを設定すると既定の組み込みガード (sec-default@builtin) が置き換えられるため、sec-default@builtinをリストに含めて組み込みの保護を維持しつつ独自の mod の実行順を制御したい場合に使う。
英語原文
List the managed plugins whose mods run before every mod a user installs, in the listed order. When you set this key in managed settings, name sec-default@builtin in the list to keep the built-in guard. In managed settings, Claude Code skips an id whose plugin doesn't count as your organization's. See Install your organization's mods and set the order for those conditions and for how the two ordering keys work together.