Skip to content

Commit 5cf3402

Browse files
fix: add working directory to wix's shortcut (#1021)
* fix: add working directory to wix's shortcut * chore: add change file Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
1 parent 1d9dc18 commit 5cf3402

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

.changes/wix-working-directory.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"tauri-bundler": patch
3+
---
4+
5+
Set the Windows installer (WiX) `WorkingDirectory` field to `INSTALLDIR` so the app can read paths relatively (previously resolving to `C:\Windows\System32`).

cli/tauri-bundler/src/bundle/templates/main.wxs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,8 @@
103103
Name="{{{product_name}}}"
104104
Description="Runs {{{product_name}}}"
105105
Target="[!Path]"
106-
Icon="ProductIcon">
106+
Icon="ProductIcon"
107+
WorkingDirectory="INSTALLDIR">
107108
<ShortcutProperty Key="System.AppUserModel.ID" Value="{{{manufacturer}}}"/>
108109
</Shortcut>
109110
<RemoveFolder Id="ApplicationProgramsFolder" On="uninstall"/>

0 commit comments

Comments
 (0)