@kandiforge/kandi-cli 9.1.1 → 9.2.0
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/package.json +1 -1
- package/scripts/install.js +4 -2
package/package.json
CHANGED
package/scripts/install.js
CHANGED
|
@@ -6,7 +6,7 @@ const https = require('https');
|
|
|
6
6
|
const { execSync } = require('child_process');
|
|
7
7
|
const crypto = require('crypto');
|
|
8
8
|
|
|
9
|
-
const RELEASE_VERSION = '9.
|
|
9
|
+
const RELEASE_VERSION = '9.2.0';
|
|
10
10
|
const DISTRIBUTION_REPO = 'KandiForge/distribution';
|
|
11
11
|
const BINARIES_PATH = 'kandi-cli/binaries';
|
|
12
12
|
|
|
@@ -108,7 +108,9 @@ async function install() {
|
|
|
108
108
|
|
|
109
109
|
// Extract the binary
|
|
110
110
|
console.log('Extracting binary...');
|
|
111
|
-
|
|
111
|
+
// Use appropriate flag based on archive type: -C for tar, -d for unzip
|
|
112
|
+
const destFlag = platform === 'win32' ? '-d' : '-C';
|
|
113
|
+
execSync(`${extractCmd} "${tempFile}" ${destFlag} "${binDir}"`, { stdio: 'inherit' });
|
|
112
114
|
|
|
113
115
|
// Clean up archive
|
|
114
116
|
fs.unlinkSync(tempFile);
|