Unable to package a installer.
I created a web app wrap using nativefier --name ynu_courses -a ia32 --app-version 1.0.0 --build-version 1.0.0 -c --disable-context-menu http://113.55.12.52:50120/, then I want to create a installer for this built app. Then I write a script named build.js which the contents of the file is belows.
// build.js
var electronInstaller = require('electron-winstaller');
resultPromise = electronInstaller.createWindowsInstaller({
appDirectory: 'ynu_courses-win32-ia32',
outputDirectory: 'dist',
authors: 'Liu.D.H',
exe: 'ynu-courses.exe',
version: '1.0.0',
title: 'ynu-courses'
});
resultPromise.then(() => console.log("It worked!"), (e) => console.log(`No dice: ${e.message}`));
D:\code\weixin\ynu_courses>node build.js
No dice: Failed with exit code: 4294967295
Output:
System.AggregateException: One or more errors occurred. ---> System.Exception: Failed to compile WiX template, command invoked was: 'candle.exe -nologo -ext WixNetFxExtension -out "D:\code\weixin\ynu_courses\dist\Setup.wixobj" "D:\code\weixin\ynu_courses\dist\Setup.wxs"'
Output was:
Setup.wxs
D:\code\weixin\ynu_courses\dist\Setup.wxs(3) : error CNDL0108 : The Product/@Version attribute's value, '!(bind.FileVersion.ynu-courses-nativefier-0256db.exe)', is not a valid version. Legal version values should look like 'x.x.x.x' where x is an integer from 0 to 65534.
D:\code\weixin\ynu_courses\dist\Setup.wxs(3) : error CNDL0010 : The Product/@Version attribute was not found; it is required.
I noted the error was related to the Product/@Version attribute, but I have specified in the build.js.
Any suggestion about this problem.
Is there a Solution for this problem?
I also have this issue. A setup.exe is created and works ok, but the .wix always fails. If you only need the .exe, check your output folder and see if it's there.
Now using electron-forge instead. Works pretty well.
Had the same problem and fixed it with the help of @Kurmaev in #203 (10x Kurmaev)
In my case, my app name in package.json was "xxxx-xxxxx", when I removed the (-), having it "xxxxxxxx", I was able to successfully build the installer. 🤘
Problem is actual. If set name in package.json without any - (dashes) its works. Also, possible to set name in configuration without - (dashes) and its works too.
In all cases installer works fine. You can just ignore this error.
Can @MarshallOfSound please fix it?