diff --git a/packages/create/templates/common/package.json b/packages/create/templates/common/package.json index 053c52e3..dd7b657d 100644 --- a/packages/create/templates/common/package.json +++ b/packages/create/templates/common/package.json @@ -27,6 +27,31 @@ //%endif "@clusterio/lib": "^__clusterio_version__" }, +//%if controller | host | ctl + "peerDependenciesMeta": { +//%endif +//%if controller + "@clusterio/controller": { + "optional": true +//%endif +//%if controller & host | controller & ctl + }, +//%endif +//%if host + "@clusterio/host": { + "optional": true +//%endif +//%if host & ctl + }, +//%endif +//%if ctl + "@clusterio/ctl": { + "optional": true +//%endif +//%if controller | host | ctl + } + }, +//%endif "devDependencies": { //%// Typescript and type declarations //%if typescript diff --git a/plugins/global_chat/package.json b/plugins/global_chat/package.json index ddd07282..6947e542 100644 --- a/plugins/global_chat/package.json +++ b/plugins/global_chat/package.json @@ -38,6 +38,14 @@ "@clusterio/host": "workspace:^", "@clusterio/lib": "workspace:^" }, + "peerDependenciesMeta": { + "@clusterio/ctl": { + "optional": true + }, + "@clusterio/host": { + "optional": true + } + }, "dependencies": { "@sinclair/typebox": "catalog:" }, diff --git a/plugins/inventory_sync/package.json b/plugins/inventory_sync/package.json index 8df3e88b..61476bf4 100644 --- a/plugins/inventory_sync/package.json +++ b/plugins/inventory_sync/package.json @@ -38,6 +38,14 @@ "@clusterio/host": "workspace:^", "@clusterio/lib": "workspace:^" }, + "peerDependenciesMeta": { + "@clusterio/controller": { + "optional": true + }, + "@clusterio/host": { + "optional": true + } + }, "dependencies": { "@sinclair/typebox": "catalog:" }, diff --git a/plugins/player_auth/package.json b/plugins/player_auth/package.json index 1aadb56d..a2535d16 100644 --- a/plugins/player_auth/package.json +++ b/plugins/player_auth/package.json @@ -38,6 +38,14 @@ "@clusterio/host": "workspace:^", "@clusterio/lib": "workspace:^" }, + "peerDependenciesMeta": { + "@clusterio/controller": { + "optional": true + }, + "@clusterio/host": { + "optional": true + } + }, "dependencies": { "@sinclair/typebox": "catalog:", "jsonwebtoken": "catalog:", diff --git a/plugins/research_sync/package.json b/plugins/research_sync/package.json index fa7e36b8..e491db89 100644 --- a/plugins/research_sync/package.json +++ b/plugins/research_sync/package.json @@ -38,6 +38,14 @@ "@clusterio/host": "workspace:^", "@clusterio/lib": "workspace:^" }, + "peerDependenciesMeta": { + "@clusterio/controller": { + "optional": true + }, + "@clusterio/host": { + "optional": true + } + }, "dependencies": { "@sinclair/typebox": "catalog:" }, diff --git a/plugins/statistics_exporter/package.json b/plugins/statistics_exporter/package.json index c522983f..05276508 100644 --- a/plugins/statistics_exporter/package.json +++ b/plugins/statistics_exporter/package.json @@ -37,6 +37,14 @@ "@clusterio/host": "workspace:^", "@clusterio/lib": "workspace:^" }, + "peerDependenciesMeta": { + "@clusterio/controller": { + "optional": true + }, + "@clusterio/host": { + "optional": true + } + }, "devDependencies": { "@clusterio/web_ui": "workspace:^", "@clusterio/host": "workspace:^", diff --git a/plugins/subspace_storage/package.json b/plugins/subspace_storage/package.json index 5ff1bc61..2ddaa3f9 100644 --- a/plugins/subspace_storage/package.json +++ b/plugins/subspace_storage/package.json @@ -38,6 +38,14 @@ "@clusterio/host": "workspace:^", "@clusterio/lib": "workspace:^" }, + "peerDependenciesMeta": { + "@clusterio/controller": { + "optional": true + }, + "@clusterio/host": { + "optional": true + } + }, "dependencies": { "@sinclair/typebox": "catalog:" },