Skip to content

Commit

Permalink
fix(nsis): set locale id for legalTrademarks
Browse files Browse the repository at this point in the history
Closes #672
  • Loading branch information
develar committed Aug 30, 2016
1 parent b739f42 commit 91addfe
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 9 deletions.
2 changes: 1 addition & 1 deletion docs/Options.md
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ See [NSIS target notes](https://github.com/electron-userland/electron-builder/wi
| installerHeaderIcon | <a name="NsisOptions-installerHeaderIcon"></a>*one-click installer only.* The path to header icon (above the progress bar), relative to the project directory. Defaults to `build/installerHeaderIcon.ico` or application icon.
| include | <a name="NsisOptions-include"></a>The path to NSIS include script to customize installer. Defaults to `build/installer.nsh`. See [Custom NSIS script](https://github.com/electron-userland/electron-builder/wiki/NSIS#custom-nsis-script).
| script | <a name="NsisOptions-script"></a>The path to NSIS script to customize installer. Defaults to `build/installer.nsi`. See [Custom NSIS script](https://github.com/electron-userland/electron-builder/wiki/NSIS#custom-nsis-script).
| language | <a name="NsisOptions-language"></a>* Hex LCID, defaults to `1033`(`English - United States`, see https://msdn.microsoft.com/en-au/goglobal/bb964664.aspx?f=255&MSPPError=-2147217396).
| language | <a name="NsisOptions-language"></a>* LCID Dec, defaults to `1033`(`English - United States`, see https://msdn.microsoft.com/en-au/goglobal/bb964664.aspx?f=255&MSPPError=-2147217396).

<a name="LinuxBuildOptions"></a>
### `.build.linux`
Expand Down
2 changes: 1 addition & 1 deletion src/metadata.ts
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@ export interface NsisOptions {
readonly script?: string | null

/*
* Hex LCID, defaults to `1033`(`English - United States`, see https://msdn.microsoft.com/en-au/goglobal/bb964664.aspx?f=255&MSPPError=-2147217396).
* LCID Dec, defaults to `1033`(`English - United States`, see https://msdn.microsoft.com/en-au/goglobal/bb964664.aspx?f=255&MSPPError=-2147217396).
*/
readonly language?: string | null
}
Expand Down
2 changes: 1 addition & 1 deletion src/targets/nsis.ts
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ export default class NsisTarget extends Target {
`/LANG=${localeId} FileDescription "${appInfo.description}"`,
`/LANG=${localeId} FileVersion "${appInfo.buildVersion}"`,
]
use(this.packager.platformSpecificBuildOptions.legalTrademarks, it => versionKey.push(`LegalTrademarks "${it}"`))
use(this.packager.platformSpecificBuildOptions.legalTrademarks, it => versionKey.push(`/LANG=${localeId} LegalTrademarks "${it}"`))

const commands: any = {
OutFile: `"${installerPath}"`,
Expand Down
5 changes: 4 additions & 1 deletion test/src/nsisTest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,10 @@ test.ifNotCiOsx("boring", app({
nsis: {
oneClick: false,
language: "1031",
}
},
win: {
legalTrademarks: "My Trademark"
},
}
}
}, {signed: true}))
Expand Down
5 changes: 0 additions & 5 deletions test/src/winPackagerTest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,6 @@ test.ifDevOrWinCi("beta version", app({
targets: Platform.WINDOWS.createTarget(["squirrel", "nsis"]),
devMetadata: <any>{
version: "3.0.0-beta.2",
build: {
win: {
legalTrademarks: "My Trademark"
},
},
}
}))

Expand Down

0 comments on commit 91addfe

Please sign in to comment.