Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 9 additions & 8 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
name: Release

# Publish a Windows installer when a version tag is pushed, e.g.:
# Publish Windows installers when a version tag is pushed, e.g.:
# git tag v1.0.0
# git push origin v1.0.0
# Builds the NSIS installer with electron-builder and attaches it to a GitHub
# Release created for the tag.
# Builds the NSIS installers (x64 + ARM64) with electron-builder and attaches
# them to a GitHub Release created for the tag.

on:
push:
Expand Down Expand Up @@ -58,9 +58,10 @@ jobs:
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
$setup = Get-ChildItem dist -Filter '*Setup*.exe' | Select-Object -First 1
if (-not $setup) { $setup = Get-ChildItem dist -Filter '*.exe' | Select-Object -First 1 }
if (-not $setup) { Write-Host "No installer .exe found in dist/"; exit 1 }
$installers = @(Get-ChildItem dist -Filter '*.exe' -File)
if ($installers.Count -eq 0) { Write-Host "No installer .exe found in dist/"; exit 1 }
Write-Host "Attaching $($installers.Count) installer(s):"
$installers | ForEach-Object { Write-Host " - $($_.Name)" }
$tag = $env:GITHUB_REF_NAME
$notes = "Automated Windows x64 installer for M2_LOG $tag.`n`nRun the Setup .exe and follow the interactive installer."
gh release create $tag $setup.FullName --title "M2_LOG $tag" --notes $notes
$notes = "Automated Windows installers (x64 + ARM64) for M2_LOG $tag.`n`nDownload the installer matching your CPU architecture, run it, and follow the interactive installer."
gh release create $tag $installers.FullName --title "M2_LOG $tag" --notes $notes
Loading