electron-wix-msi icon indicating copy to clipboard operation
electron-wix-msi copied to clipboard

No Documentation For Localization Files

Open dapperdandev opened this issue 6 years ago • 2 comments

I need to modify the LicenseAgreementDlg variables with the following .wxl per the official Wix Documentation. Source: http://wixtoolset.org/documentation/manual/v3/wixui/wixui_customizations.html

<?xml version="1.0" encoding="utf-8"?>
<WixLocalization Culture="en-us" xmlns="http://schemas.microsoft.com/wix/2006/localization">
    <String Id="LicenseAgreementDlgDescription">Please read</String>
    <String Id="LicenseAgreementDlgLicenseAcceptedCheckBox">I agree</String>
</WixLocalization>

There's no documentation in this repository for providing a .wxl. How is this accomplished?

dapperdandev avatar Apr 10 '19 22:04 dapperdandev

I also need to add a license agreement, but can't figure out if it is possitble. Seems just as easy to use WiX toolkit directly since I need to build the application first and code-sign before creating the msi anyway.

Or the documentation for this module must be updated, because this is just too much investigation to get started.

FarbrorGarbo avatar Apr 29 '19 14:04 FarbrorGarbo

@FarbrorGarbo Here's the steps. It seems like a lot, but it's not too bad:

  1. First, you need to fix creator.ts. It doesn't support msiCreator.ui.template as is. There's a PR that's been sitting out there to fix it: https://github.com/felixrieseberg/electron-wix-msi/pull/36/files

I also have a fork that adds some other features. I may open a pr in a couple of weeks, but I need to make the code consistent with the original developer's patterns.

Here's my fork: https://github.com/djbreen7/electron-wix-msi

  1. You need to provide the <UI>...</UI> code to msiCreator.ui.template.

const wixUiTemplate = `<UI>Template code goes here</UI>`;
export const msiCreator = new MSICreator({
    // miscellaneous properties
    ...
    ui: {
        template: wixUiTemplate
    }
    ...
  1. Your <UI></UI> code needs to have the element: <UIRef Id="WixUI_Common" /> for you to be able to use the license agreement code. Fortunately, the default template is mostly similar to what you need: https://github.com/felixrieseberg/electron-wix-msi/blob/master/static/ui.xml.

  2. After that, it's just a matter using the wix documentation: http://wixtoolset.org/documentation/manual/v3/wixui/wixui_customizations.html

TIP: If you just want the default license agreement without any customization to the installer ui, use <UIRef Id="WixUI_Minimal" /> instead, and you don't have to provide any dialog Publish elements.

dapperdandev avatar Apr 30 '19 18:04 dapperdandev