File tree Expand file tree Collapse file tree 1 file changed +43
-0
lines changed
Expand file tree Collapse file tree 1 file changed +43
-0
lines changed Original file line number Diff line number Diff line change @@ -102,6 +102,49 @@ if (require('electron-squirrel-startup')) app.quit();
102102```
103103{% endcode %}
104104
105+ ### Spaces in the app name
106+
107+ Squirrel.Windows can behave unexpectedly when application names contain spaces. You can use the following setup in this case, which works well:
108+
109+ {% code title="package.json" %}
110+ ``` json5
111+ {
112+ // Hyphenated version
113+ " name" : " app-name" ,
114+ // The app name with spaces (will be shown to your users)
115+ " productName" : " App Name" ,
116+ // ...
117+ }
118+ ```
119+ {% endcode %}
120+
121+ {% code title="forge.config.ts" %}
122+ ``` typescript
123+ const config: ForgeConfig = {
124+ makers: [
125+ new MakerSquirrel ({
126+ // CamelCase version without spaces
127+ name: " AppName" ,
128+ // ...
129+ }),
130+ ],
131+ // ...
132+ }
133+ ```
134+ {% endcode %}
135+
136+ Additionally, you'll need to set the App User Model ID from your main process like this:
137+
138+ {% code title="main.ts" %}
139+ ``` typescript
140+ app .setAppUserModelId (" com.squirrel.AppName.AppName" );
141+ ```
142+ {% endcode %}
143+
144+ Squirrel.Windows will use the ` productName ` from your ` package.json ` for any user-facing strings and for the name of your ` Setup.exe ` .
145+
146+ It will use the camel-cased ` name ` from the ` MakerSquirrel ` config for the NuGet package name. NuGet package names cannot contain spaces.
147+
105148## Debugging
106149
107150For advanced debug logging for this maker, add the ` DEBUG=electron-windows-installer* ` environment variable.
You can’t perform that action at this time.
0 commit comments