@aiyiran/myclaw 1.0.81 → 1.0.82
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/index.js +2 -1
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -397,13 +397,14 @@ pause
|
|
|
397
397
|
fs.writeFileSync(batPath, batContent.replace(/\n/g, '\r\n'), 'utf8');
|
|
398
398
|
|
|
399
399
|
// 用 PowerShell 创建带图标的桌面快捷方式 + 刷新桌面
|
|
400
|
+
const iconPath = path.join(__dirname, 'assets', 'openclaw.ico');
|
|
400
401
|
const psScript = `
|
|
401
402
|
$ws = New-Object -ComObject WScript.Shell
|
|
402
403
|
$sc = $ws.CreateShortcut('${lnkPath.replace(/\\/g, '\\\\')}')
|
|
403
404
|
$sc.TargetPath = '${batPath.replace(/\\/g, '\\\\')}'
|
|
404
405
|
$sc.WorkingDirectory = '${myClawDir.replace(/\\/g, '\\\\')}'
|
|
405
406
|
$sc.WindowStyle = 1
|
|
406
|
-
$sc.IconLocation = '
|
|
407
|
+
$sc.IconLocation = '${iconPath.replace(/\\/g, '\\\\')}'
|
|
407
408
|
$sc.Description = 'OpenClaw'
|
|
408
409
|
$sc.Save()
|
|
409
410
|
Add-Type -TypeDefinition 'using System; using System.Runtime.InteropServices; public class Shell { [DllImport("shell32.dll")] public static extern void SHChangeNotify(int e, int f, IntPtr i1, IntPtr i2); }' -ErrorAction SilentlyContinue
|