|
121 | 121 | <!-- Electron Builder uses title for the installation dir on Linux, but it should not have spaces --> |
122 | 122 | <LinuxPrefix>linux</LinuxPrefix> |
123 | 123 | <ElectronTitle>$(Title)</ElectronTitle> |
124 | | - <ElectronTitle Condition="'$(RuntimeIdentifier.StartsWith($(LinuxPrefix)))' == 'true'">$(Title.Replace(' ', '-'))</ElectronTitle> |
| 124 | + <ElectronTitle Condition="'$(ElectronRuntimeIdentifier.StartsWith($(LinuxPrefix)))' == 'true'">$(Title.Replace(' ', '-'))</ElectronTitle> |
125 | 125 | </PropertyGroup> |
126 | 126 |
|
127 | 127 | <ItemGroup> |
|
365 | 365 | <Target Name="ElectronCheckVersionMismatch"> |
366 | 366 |
|
367 | 367 | <PropertyGroup> |
368 | | - <ElectronArch Condition="'$(RuntimeIdentifier)' == 'win-x64'">x64</ElectronArch> |
369 | | - <ElectronArch Condition="'$(RuntimeIdentifier)' == 'win-x86'">ia32</ElectronArch> |
370 | | - <ElectronArch Condition="'$(RuntimeIdentifier)' == 'win-arm64'">arm64</ElectronArch> |
371 | | - <ElectronArch Condition="'$(RuntimeIdentifier)' == 'linux-x64'">x64</ElectronArch> |
372 | | - <ElectronArch Condition="'$(RuntimeIdentifier)' == 'linux-arm'">armv7l</ElectronArch> |
373 | | - <ElectronArch Condition="'$(RuntimeIdentifier)' == 'linux-arm64'">arm64</ElectronArch> |
374 | | - <ElectronArch Condition="'$(RuntimeIdentifier)' == 'osx-x64'">x64</ElectronArch> |
375 | | - <ElectronArch Condition="'$(RuntimeIdentifier)' == 'osx-arm64'">arm64</ElectronArch> |
376 | | - |
377 | | - <ElectronPlatform Condition="'$(RuntimeIdentifier)' == 'win-x64' OR '$(RuntimeIdentifier)' == 'win-x86' OR '$(RuntimeIdentifier)' == 'win-arm64'">win</ElectronPlatform> |
378 | | - <ElectronPlatform Condition="'$(RuntimeIdentifier)' == 'linux-x64' OR '$(RuntimeIdentifier)' == 'linux-arm' OR '$(RuntimeIdentifier)' == 'linux-arm64'">linux</ElectronPlatform> |
379 | | - <ElectronPlatform Condition="'$(RuntimeIdentifier)' == 'osx-x64' OR '$(RuntimeIdentifier)' == 'osx-arm64'">mac</ElectronPlatform> |
| 368 | + <ElectronArch Condition="'$(ElectronRuntimeIdentifier)' == 'win-x64'">x64</ElectronArch> |
| 369 | + <ElectronArch Condition="'$(ElectronRuntimeIdentifier)' == 'win-x86'">ia32</ElectronArch> |
| 370 | + <ElectronArch Condition="'$(ElectronRuntimeIdentifier)' == 'win-arm64'">arm64</ElectronArch> |
| 371 | + <ElectronArch Condition="'$(ElectronRuntimeIdentifier)' == 'linux-x64'">x64</ElectronArch> |
| 372 | + <ElectronArch Condition="'$(ElectronRuntimeIdentifier)' == 'linux-arm'">armv7l</ElectronArch> |
| 373 | + <ElectronArch Condition="'$(ElectronRuntimeIdentifier)' == 'linux-arm64'">arm64</ElectronArch> |
| 374 | + <ElectronArch Condition="'$(ElectronRuntimeIdentifier)' == 'osx-x64'">x64</ElectronArch> |
| 375 | + <ElectronArch Condition="'$(ElectronRuntimeIdentifier)' == 'osx-arm64'">arm64</ElectronArch> |
| 376 | + |
| 377 | + <ElectronPlatform Condition="'$(ElectronRuntimeIdentifier)' == 'win-x64' OR '$(ElectronRuntimeIdentifier)' == 'win-x86' OR '$(ElectronRuntimeIdentifier)' == 'win-arm64'">win</ElectronPlatform> |
| 378 | + <ElectronPlatform Condition="'$(ElectronRuntimeIdentifier)' == 'linux-x64' OR '$(ElectronRuntimeIdentifier)' == 'linux-arm' OR '$(ElectronRuntimeIdentifier)' == 'linux-arm64'">linux</ElectronPlatform> |
| 379 | + <ElectronPlatform Condition="'$(ElectronRuntimeIdentifier)' == 'osx-x64' OR '$(ElectronRuntimeIdentifier)' == 'osx-arm64'">mac</ElectronPlatform> |
380 | 380 |
|
381 | 381 | <!-- npm uses different OS names than Electron --> |
382 | 382 | <NpmOs Condition="'$(ElectronPlatform)' == 'win'">win32</NpmOs> |
|
385 | 385 |
|
386 | 386 | <!-- npm CPU is same as ElectronArch except for linux-arm --> |
387 | 387 | <NpmCpu>$(ElectronArch)</NpmCpu> |
388 | | - <NpmCpu Condition="'$(RuntimeIdentifier)' == 'linux-arm'">arm</NpmCpu> |
| 388 | + <NpmCpu Condition="'$(ElectronRuntimeIdentifier)' == 'linux-arm'">arm</NpmCpu> |
389 | 389 |
|
390 | 390 | <_CurrentOSPlatform Condition="$([MSBuild]::IsOSPlatform('Windows'))">win</_CurrentOSPlatform> |
391 | 391 | <_CurrentOSPlatform Condition="$([MSBuild]::IsOSPlatform('Linux'))">linux</_CurrentOSPlatform> |
|
522 | 522 |
|
523 | 523 | <Error Condition="'$(_IsPlatformMismatch)' == 'true'" |
524 | 524 | Code="ELECTRON100" |
525 | | - Text="The target RuntimeIdentifier '$(RuntimeIdentifier)' (platform: $(ElectronPlatform)) does not match the current operating system ($(_CurrentOSPlatform)). |
| 525 | + Text="The target RuntimeIdentifier '$(ElectronRuntimeIdentifier)' (platform: $(ElectronPlatform)) does not match the current operating system ($(_CurrentOSPlatform)). |
526 | 526 |
|
527 | 527 | Electron applications must be built on the target operating system: |
528 | 528 | - Windows targets (win-x64, win-x86, win-arm64) must be built on Windows |
@@ -645,7 +645,10 @@ For more information, see: https://github.com/ElectronNET/Electron.NET/wiki/Migr |
645 | 645 | </PropertyGroup> |
646 | 646 |
|
647 | 647 | <PropertyGroup> |
648 | | - <_NpxCmd>npx electron-builder --config=./$(ElectronBuilderJson) --$(ElectronPlatform) --$(ElectronArch) -c.electronVersion=$(ElectronVersion) -c.directories.output "$(ElectronPublishUrlFullPath)" $(ElectronPaParams)</_NpxCmd> |
| 648 | + <_NpxCmd>npx electron-builder --config=./$(ElectronBuilderJson)</_NpxCmd> |
| 649 | + <_NpxCmd Condition="'$(IsLinuxWsl)' == 'true'">$(_NpxCmd) --$(ElectronPlatform)</_NpxCmd> |
| 650 | + <_NpxCmd Condition="'$(IsLinuxWsl)' == 'true'">$(_NpxCmd) --$(ElectronArch)</_NpxCmd> |
| 651 | + <_NpxCmd>$(_NpxCmd) -c.electronVersion=$(ElectronVersion) -c.directories.output "$(ElectronPublishUrlFullPath)" $(ElectronPaParams)</_NpxCmd> |
649 | 652 | <_NpxCmd Condition="'$(IsLinuxWsl)' == 'true'">wsl bash -ic '$(_NpxCmd)'</_NpxCmd> |
650 | 653 | </PropertyGroup> |
651 | 654 |
|
|
0 commit comments