kiosapi 0.1.18 → 0.1.19
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/dist/agent/tools.js +5 -1
- package/package.json +1 -1
package/dist/agent/tools.js
CHANGED
|
@@ -306,7 +306,11 @@ export async function jalankan(perintah) {
|
|
|
306
306
|
let output = '';
|
|
307
307
|
let limitHit = false;
|
|
308
308
|
process.stdout.write('\n');
|
|
309
|
-
|
|
309
|
+
// On Windows, explicitly use cmd.exe so Windows commands (findstr, dir, etc.) work correctly
|
|
310
|
+
// even when the CLI is launched from a Git Bash or similar POSIX-shell terminal.
|
|
311
|
+
const proc = process.platform === 'win32'
|
|
312
|
+
? spawn('cmd.exe', ['/c', perintah], { cwd: ROOT })
|
|
313
|
+
: spawn(perintah, { cwd: ROOT, shell: true });
|
|
310
314
|
const onData = (chunk) => {
|
|
311
315
|
const text = chunk.toString();
|
|
312
316
|
output += text;
|