Skip to content

Commit f52b147

Browse files
JamesLefrerefrolic
andauthored
chore(cli): print mud version in deploy (#3476)
Co-authored-by: Kevin Ingersoll <kingersoll@gmail.com>
1 parent bc49b98 commit f52b147

2 files changed

Lines changed: 8 additions & 0 deletions

File tree

.changeset/wild-starfishes-yell.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@latticexyz/cli": patch
3+
---
4+
5+
Deploy now prints the current MUD CLI version for easier debugging.

packages/cli/src/runDeploy.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import path from "node:path";
22
import { existsSync, mkdirSync, readFileSync, writeFileSync } from "node:fs";
3+
import packageJson from "../package.json";
34
import { InferredOptionTypes, Options } from "yargs";
45
import { deploy } from "./deploy/deploy";
56
import { createWalletClient, http, Hex, isHex, stringToHex } from "viem";
@@ -71,6 +72,8 @@ export async function runDeploy(opts: DeployOptions): Promise<WorldDeploy> {
7172
const config = (await loadConfig(configPath)) as WorldConfig;
7273
const rootDir = path.dirname(configPath);
7374

75+
console.log(chalk.green(`\nUsing ${packageJson.name}@${packageJson.version}`));
76+
7477
if (opts.printConfig) {
7578
console.log(chalk.green("\nResolved config:\n"), JSON.stringify(config, null, 2));
7679
}

0 commit comments

Comments
 (0)