agent-takkub 1.0.39 → 1.0.41
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
|
package/npm/scripts/shortcut.js
CHANGED
|
@@ -93,6 +93,25 @@ function createMac() {
|
|
|
93
93
|
stdio: 'ignore',
|
|
94
94
|
});
|
|
95
95
|
}
|
|
96
|
+
|
|
97
|
+
// Also install under ~/Applications so macOS Launchpad indexes and shows
|
|
98
|
+
// the app icon. Best-effort only — a missing/unwritable ~/Applications, or
|
|
99
|
+
// `cp`/`rm` being unavailable, just skips the Launchpad copy; the Desktop
|
|
100
|
+
// launcher above still works either way.
|
|
101
|
+
const userAppsDir = path.join(os.homedir(), 'Applications');
|
|
102
|
+
const userAppPath = path.join(userAppsDir, 'Takkub Cockpit.app');
|
|
103
|
+
try {
|
|
104
|
+
fs.mkdirSync(userAppsDir, { recursive: true });
|
|
105
|
+
// Remove any existing copy first so a re-run overwrites cleanly instead
|
|
106
|
+
// of merging with (possibly stale) files from a prior install.
|
|
107
|
+
if (fs.existsSync(userAppPath)) {
|
|
108
|
+
fs.rmSync(userAppPath, { recursive: true, force: true });
|
|
109
|
+
}
|
|
110
|
+
spawnSync('cp', ['-R', appDir, userAppsDir], { stdio: 'ignore' });
|
|
111
|
+
} catch (_e) {
|
|
112
|
+
/* best-effort */
|
|
113
|
+
}
|
|
114
|
+
|
|
96
115
|
return fs.existsSync(path.join(macos, 'launch')) ? appDir : null;
|
|
97
116
|
}
|
|
98
117
|
|
package/package.json
CHANGED