tauri打包失败Error failed to bundle project: error running light.exe解决办法

Running light to produce D:\a\PakePlus\PakePlus\src-tauri\target\release\bundle\msi\快手_0.0.1_x64_en-US.msi

Error failed to bundle project: error running light.exe

 ELIFECYCLE  Command failed with exit code 1.

Error: Command failed with exit code 1: pnpm tauri build

在 Tauri 使用 GitHub Actions 打包 Windows MSI 时,如果遇到 error running light.exe 的错误,特别是在打包路径中包含非 ASCII 字符(如中文字符 抖音)时,问题可能与 WiX Toolset 不支持文件路径中的非 ASCII 字符有关。

解决办法

1.避免使用非ASCII 字符,只能使用英文和数字的组合形式。

2.配置tauri配置文件,不打包msi的安装包,具体可以看官方文档的配置说明:Configuration | Tauri Apps

只需要配置成一个数组就可以了:["deb", "appimage", "nsis", "app", "dmg", "updater"]

猜你喜欢

转载自blog.csdn.net/weixin_44786530/article/details/143141552