@mandors/cli 0.0.5 → 0.0.6
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.
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/npm/lib/install.js
CHANGED
|
@@ -59,10 +59,17 @@ function useBundledBinary(platform, arch) {
|
|
|
59
59
|
const filename = `mandor-${platform}-${arch}`;
|
|
60
60
|
const bundledBinary = path.join(BUNDLE_DIR, filename, 'mandor');
|
|
61
61
|
|
|
62
|
+
console.log(`DEBUG: Checking bundled binary at: ${bundledBinary}`);
|
|
63
|
+
console.log(`DEBUG: BUNDLE_DIR: ${BUNDLE_DIR}`);
|
|
64
|
+
console.log(`DEBUG: Files in BUNDLE_DIR: ${fs.existsSync(BUNDLE_DIR) ? fs.readdirSync(BUNDLE_DIR) : 'not exists'}`);
|
|
65
|
+
|
|
62
66
|
if (!fs.existsSync(bundledBinary)) {
|
|
67
|
+
console.log(`DEBUG: Bundled binary not found`);
|
|
63
68
|
return null;
|
|
64
69
|
}
|
|
65
70
|
|
|
71
|
+
console.log(`DEBUG: Found bundled binary`);
|
|
72
|
+
|
|
66
73
|
const cacheDir = path.join(os.homedir(), '.mandor', 'bin');
|
|
67
74
|
if (!fs.existsSync(cacheDir)) {
|
|
68
75
|
fs.mkdirSync(cacheDir, { recursive: true });
|
|
@@ -75,6 +82,7 @@ function useBundledBinary(platform, arch) {
|
|
|
75
82
|
fs.chmodSync(dest, '755');
|
|
76
83
|
return dest;
|
|
77
84
|
} catch (e) {
|
|
85
|
+
console.log(`DEBUG: Failed to copy: ${e.message}`);
|
|
78
86
|
return null;
|
|
79
87
|
}
|
|
80
88
|
}
|