xiaozuoassistant 0.2.11 → 0.2.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/cli.js +4 -2
- package/package.json +1 -1
package/bin/cli.js
CHANGED
|
@@ -412,8 +412,10 @@ async function updateApp() {
|
|
|
412
412
|
const pidFile = getPidFilePath();
|
|
413
413
|
|
|
414
414
|
// Get local version
|
|
415
|
-
const
|
|
416
|
-
const
|
|
415
|
+
const packageJsonPath = path.join(__dirname, '..', 'package.json');
|
|
416
|
+
const packageJsonContent = fs.readFileSync(packageJsonPath, 'utf-8');
|
|
417
|
+
const packageJson = JSON.parse(packageJsonContent);
|
|
418
|
+
const localVersion = packageJson.version;
|
|
417
419
|
console.log(`[CLI] 当前版本: ${localVersion}`);
|
|
418
420
|
|
|
419
421
|
// Get remote version
|