@adhdev/daemon-core 0.5.30 → 0.5.31
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
CHANGED
|
@@ -24,15 +24,13 @@ import { LOG } from '../logging/logger.js';
|
|
|
24
24
|
let pty: any;
|
|
25
25
|
try {
|
|
26
26
|
pty = require('node-pty');
|
|
27
|
-
// node-pty
|
|
27
|
+
// node-pty ships spawn-helper without +x on macOS (npm umask issue) — fix it
|
|
28
28
|
if (os.platform() !== 'win32') {
|
|
29
29
|
try {
|
|
30
30
|
const fs = require('fs');
|
|
31
|
-
// require.resolve('node-pty') → .../node-pty/lib/index.js
|
|
32
|
-
// prebuilds/ is at .../node-pty/prebuilds/, not .../node-pty/lib/prebuilds/
|
|
33
31
|
const ptyDir = path.resolve(path.dirname(require.resolve('node-pty')), '..');
|
|
34
|
-
const
|
|
35
|
-
const helper = path.join(ptyDir, 'prebuilds',
|
|
32
|
+
const platformArch = `${os.platform()}-${os.arch()}`;
|
|
33
|
+
const helper = path.join(ptyDir, 'prebuilds', platformArch, 'spawn-helper');
|
|
36
34
|
if (fs.existsSync(helper)) {
|
|
37
35
|
const stat = fs.statSync(helper);
|
|
38
36
|
if (!(stat.mode & 0o111)) {
|
|
@@ -43,7 +41,7 @@ try {
|
|
|
43
41
|
} catch { /* best-effort */ }
|
|
44
42
|
}
|
|
45
43
|
} catch {
|
|
46
|
-
LOG.error('CLI', '[ProviderCliAdapter] node-pty not found.
|
|
44
|
+
LOG.error('CLI', '[ProviderCliAdapter] node-pty not found. Terminal features disabled.');
|
|
47
45
|
}
|
|
48
46
|
|
|
49
47
|
export interface CliChatMessage {
|