From 1ccd627676cb94a07e29e511db037a5f855c3096 Mon Sep 17 00:00:00 2001 From: yonada Date: Thu, 25 Apr 2024 14:11:50 +0100 Subject: [PATCH] refactor(world,cli): rename `useProxy` to `upgradeableWorldImplementation` (#2732) --- .changeset/spicy-bags-cough.md | 2 +- packages/cli/src/runDeploy.ts | 2 +- packages/world/ts/config/v2/defaults.ts | 2 +- packages/world/ts/config/v2/input.ts | 4 ++-- packages/world/ts/config/v2/output.ts | 4 ++-- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.changeset/spicy-bags-cough.md b/.changeset/spicy-bags-cough.md index d24979ce5e..5c2d4877ca 100644 --- a/.changeset/spicy-bags-cough.md +++ b/.changeset/spicy-bags-cough.md @@ -3,4 +3,4 @@ "@latticexyz/cli": patch --- -Added a `deploy.useProxy` option to the MUD config that deploys the World as an upgradable proxy contract. The proxy behaves like a regular World contract, but the underlying implementation can be upgraded by calling `setImplementation`. +Added a `deploy.upgradeableWorldImplementation` option to the MUD config that deploys the World as an upgradeable proxy contract. The proxy behaves like a regular World contract, but the underlying implementation can be upgraded by calling `setImplementation`. diff --git a/packages/cli/src/runDeploy.ts b/packages/cli/src/runDeploy.ts index 9a47b5c42c..3429e330a7 100644 --- a/packages/cli/src/runDeploy.ts +++ b/packages/cli/src/runDeploy.ts @@ -111,7 +111,7 @@ in your contracts directory to use the default anvil private key.`, worldAddress: opts.worldAddress as Hex | undefined, client, config: resolvedConfig, - withWorldProxy: configV2.deploy.useProxy, + withWorldProxy: configV2.deploy.upgradeableWorldImplementation, }); if (opts.worldAddress == null || opts.alwaysRunPostDeploy) { await postDeploy(config.postDeployScript, worldDeploy.address, rpc, profile, opts.forgeScriptOptions); diff --git a/packages/world/ts/config/v2/defaults.ts b/packages/world/ts/config/v2/defaults.ts index 034a031e25..f8982f24d8 100644 --- a/packages/world/ts/config/v2/defaults.ts +++ b/packages/world/ts/config/v2/defaults.ts @@ -19,7 +19,7 @@ export const DEPLOY_DEFAULTS = { postDeployScript: "PostDeploy", deploysDirectory: "./deploys", worldsFile: "./worlds.json", - useProxy: false, + upgradeableWorldImplementation: false, } as const; export type DEPLOY_DEFAULTS = typeof DEPLOY_DEFAULTS; diff --git a/packages/world/ts/config/v2/input.ts b/packages/world/ts/config/v2/input.ts index 40f5d69e54..e1ea7961b3 100644 --- a/packages/world/ts/config/v2/input.ts +++ b/packages/world/ts/config/v2/input.ts @@ -31,8 +31,8 @@ export type DeployInput = { deploysDirectory?: string; /** JSON file to write to with chain -> latest world deploy address (Default "./worlds.json") */ worldsFile?: string; - /** Deploy the World as an upgradable proxy */ - useProxy?: boolean; + /** Deploy the World as an upgradeable proxy */ + upgradeableWorldImplementation?: boolean; }; export type CodegenInput = { diff --git a/packages/world/ts/config/v2/output.ts b/packages/world/ts/config/v2/output.ts index 980fb76b66..99456b6af2 100644 --- a/packages/world/ts/config/v2/output.ts +++ b/packages/world/ts/config/v2/output.ts @@ -41,8 +41,8 @@ export type Deploy = { readonly deploysDirectory: string; /** JSON file to write to with chain -> latest world deploy address (Default "./worlds.json") */ readonly worldsFile: string; - /** Deploy the World as an upgradable proxy */ - readonly useProxy: boolean; + /** Deploy the World as an upgradeable proxy */ + readonly upgradeableWorldImplementation: boolean; }; export type Codegen = {