Skip to content

Commit fef48ec

Browse files
fix(execute): ensure correct CLI loading based on version mismatch (#1640)
1 parent 162c2cd commit fef48ec

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

packages/cli/bin/execute.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,13 @@ resolve("igniteui-cli", { basedir: process.cwd() }, function (err, res) {
1313
const localVersion = require(path.join(process.cwd(), "node_modules/igniteui-cli/package.json"))["version"];
1414
const globalVersion = require(path.join(__dirname, "../package.json"))["version"];
1515
if (globalVersion !== localVersion) {
16-
console.log("Different igniteui-cli global and local version");
16+
console.log("Different igniteui-cli global and local version");
17+
}
18+
if (args[0] === "ai-config") {
19+
cli = require("../lib/cli");
20+
} else {
21+
cli = require(res);
1722
}
18-
cli = require(res);
1923
} else {
2024
cli = require("../lib/cli");
2125
}

0 commit comments

Comments
 (0)