From 6ddcb835c2fefec24336760f0407e3b39e4b2778 Mon Sep 17 00:00:00 2001 From: Tomjerri1 <151880307+Tomjerri1@users.noreply.github.com> Date: Fri, 13 Nov 2026 01:33:56 +0200 Subject: [PATCH 1/2] Add release workflow and download instructions --- .github/workflows/release.yml | 51 +++++++++++++++++++++++++++++++++++ README.md | 6 +++++ 2 files changed, 57 insertions(+) create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..8a5861f --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,51 @@ +name: Release + +on: + push: + tags: + - "v*" + +permissions: + contents: write + +jobs: + release: + runs-on: windows-latest + timeout-minutes: 30 + env: + CARGO_TERM_COLOR: always + TAG: ${{ github.ref_name }} + steps: + - uses: actions/checkout@v4 + - uses: dtolnay/rust-toolchain@stable + - uses: Swatinem/rust-cache@v2 + - name: Check tag matches Cargo.toml version + shell: pwsh + run: | + $cargo = (Select-String -Path Cargo.toml -Pattern '^version\s*=\s*"(.+)"' | Select-Object -First 1).Matches[0].Groups[1].Value + $base = $env:TAG.TrimStart('v').Split('-')[0] + if ($cargo -ne $base) { + Write-Error "Tag $env:TAG does not match Cargo.toml version $cargo" + exit 1 + } + - run: cargo test --locked --all-targets + - run: cargo build --release --locked + - name: Package + shell: pwsh + run: | + $name = "snowfall-$env:TAG-windows-x64" + New-Item -ItemType Directory -Path $name | Out-Null + Copy-Item target/release/snowfall.exe $name/ + Copy-Item README.md, LICENSE $name/ + Compress-Archive -Path $name -DestinationPath "$name.zip" + $hash = (Get-FileHash "$name.zip" -Algorithm SHA256).Hash.ToLower() + "$hash $name.zip" | Out-File -Encoding ascii "$name.zip.sha256" + - name: Publish release + shell: pwsh + env: + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + $name = "snowfall-$env:TAG-windows-x64" + $flags = @() + if ($env:TAG -match '-') { $flags += '--prerelease' } + gh release create $env:TAG "$name.zip" "$name.zip.sha256" --generate-notes --title "Snowfall $env:TAG" @flags diff --git a/README.md b/README.md index 27b8dde..1d5c97e 100644 --- a/README.md +++ b/README.md @@ -12,6 +12,12 @@ A lightweight **Windows desktop overlay** that makes snow fall over your screen. - **Mouse interaction:** move the cursor over a pile to plow the snow into a mound (it spills off the window edges), or over falling flakes to push them around. On the taskbar pile the cursor gradually erases snow in a circular area. - Tray icon with a small settings window, global hotkey to quit, low CPU. +## Download + +Get the latest `snowfall-*-windows-x64.zip` from the [Releases](https://github.com/Tomjerri1/Snowfall/releases/latest) page, unzip it and run `snowfall.exe`. No installation needed. + +> Windows SmartScreen may show a warning because the executable is not code-signed. Click **More info → Run anyway**. You can verify the download with the `.sha256` file from the release. + ## Usage | Action | How | From 412beff3cb89fd1b5a1d2f680431cef3c803bc38 Mon Sep 17 00:00:00 2001 From: Tomjerri1 <151880307+Tomjerri1@users.noreply.github.com> Date: Fri, 13 Nov 2026 01:38:43 +0200 Subject: [PATCH 2/2] Release: accept exact prerelease version match --- .github/workflows/release.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 8a5861f..2a44a45 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -23,8 +23,9 @@ jobs: shell: pwsh run: | $cargo = (Select-String -Path Cargo.toml -Pattern '^version\s*=\s*"(.+)"' | Select-Object -First 1).Matches[0].Groups[1].Value - $base = $env:TAG.TrimStart('v').Split('-')[0] - if ($cargo -ne $base) { + $tagVer = $env:TAG.TrimStart('v') + $base = $tagVer.Split('-')[0] + if ($cargo -ne $tagVer -and $cargo -ne $base) { Write-Error "Tag $env:TAG does not match Cargo.toml version $cargo" exit 1 }