Skip to content

Building installer on Windows with wix options specified failed for the first ever call #2927

@kimlimjustin

Description

@kimlimjustin

Describe the bug

Building installer on Windows with Wix options (license, template) specified failed if the user never called the build before.

To Reproduce

Steps to reproduce the behavior:

  1. Run yarn create tauri-app.
  2. Select the vanilla template and leave everything simple
  3. Open the tauri-app generated
  4. Create a LICENSE file
  5. Link that LICENSE file by adding license key into tauri.bundle.windows.wix of src-tauri/tauri.conf.json with the value of ../LICENSE
  6. Run build
  7. See the error

Now to fix that:

  1. Remove the license section
  2. Run build
  3. Add back the license section
  4. Now it's ok

Expected behavior

It works fine even on the first call, cuz when calling the build via workflow, it will all fail (unless trick it by running prebuild and postbuild)

Screenshots

Code Structure:
image

Platform and Versions (required):

Operating System - Windows, version 10.0.22000 X64
Webview2 - 95.0.1020.53

Node.js environment
  Node.js - 16.0.0
  @tauri-apps/cli - 1.0.0-beta.10
  @tauri-apps/api - Not installed

Global packages
  npm - 7.10.0
  yarn - 1.22.11

Rust environment
  rustc - 1.56.0
  cargo - 1.56.0

App directory structure
/dist
/node_modules
/src-tauri

App
  tauri.rs - 1.0.0-beta.8
  build-type - bundle
  CSP - default-src blob: data: filesystem: ws: wss: http: https: tauri: 'unsafe-eval' 'unsafe-inline' 'self' img-src: 'self'
  distDir - ../dist
  devPath - ../dist
build-type
CSP

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions