Skip to content

Commit 1e698de

Browse files
Add release automation, bump version to 0.8.0 (#8)
- Update CI workflow to build on Windows, trigger on releases, and auto-package/upload PerformanceStudio and CLI zips with checksums - Bump App version 0.7.0 → 0.8.0, CLI version 0.5.0 → 0.8.0 - Fix CLI product name from "SQL Performance Studio" to "Performance Studio" Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 1bed5fa commit 1e698de

3 files changed

Lines changed: 59 additions & 6 deletions

File tree

.github/workflows/ci.yml

Lines changed: 56 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,19 @@
1-
name: CI
1+
name: Build
22

33
on:
44
push:
55
branches: [main]
66
pull_request:
7-
branches: [main]
7+
branches: [main, dev]
8+
release:
9+
types: [created, published]
10+
11+
permissions:
12+
contents: write
813

914
jobs:
1015
build-and-test:
11-
runs-on: ubuntu-latest
16+
runs-on: windows-latest
1217

1318
steps:
1419
- uses: actions/checkout@v4
@@ -34,3 +39,51 @@ jobs:
3439
3540
- name: Run tests
3641
run: dotnet test tests/PlanViewer.Core.Tests/PlanViewer.Core.Tests.csproj -c Release --no-build --verbosity normal
42+
43+
- name: Get version
44+
id: version
45+
shell: pwsh
46+
run: |
47+
$version = ([xml](Get-Content src/PlanViewer.App/PlanViewer.App.csproj)).Project.PropertyGroup.Version | Where-Object { $_ }
48+
echo "VERSION=$version" >> $env:GITHUB_OUTPUT
49+
50+
- name: Publish App
51+
run: dotnet publish src/PlanViewer.App/PlanViewer.App.csproj -c Release -o publish/App
52+
53+
- name: Publish CLI
54+
run: dotnet publish src/PlanViewer.Cli/PlanViewer.Cli.csproj -c Release -o publish/Cli
55+
56+
- name: Package release artifacts
57+
if: github.event_name == 'release'
58+
shell: pwsh
59+
run: |
60+
$version = "${{ steps.version.outputs.VERSION }}"
61+
New-Item -ItemType Directory -Force -Path releases
62+
63+
# App ZIP
64+
if (Test-Path 'README.md') { Copy-Item 'README.md' 'publish/App/' }
65+
if (Test-Path 'LICENSE') { Copy-Item 'LICENSE' 'publish/App/' }
66+
Compress-Archive -Path 'publish/App/*' -DestinationPath "releases/PerformanceStudio-$version.zip" -Force
67+
68+
# CLI ZIP
69+
if (Test-Path 'LICENSE') { Copy-Item 'LICENSE' 'publish/Cli/' }
70+
Compress-Archive -Path 'publish/Cli/*' -DestinationPath "releases/PerformanceStudioCli-$version.zip" -Force
71+
72+
- name: Generate checksums
73+
if: github.event_name == 'release'
74+
shell: pwsh
75+
run: |
76+
$checksums = Get-ChildItem releases/*.zip | ForEach-Object {
77+
$hash = (Get-FileHash $_.FullName -Algorithm SHA256).Hash.ToLower()
78+
"$hash $($_.Name)"
79+
}
80+
$checksums | Out-File -FilePath releases/SHA256SUMS.txt -Encoding utf8
81+
Write-Host "Checksums:"
82+
$checksums | ForEach-Object { Write-Host $_ }
83+
84+
- name: Upload release assets
85+
if: github.event_name == 'release'
86+
env:
87+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
88+
run: |
89+
gh release upload ${{ github.event.release.tag_name }} releases/*.zip releases/SHA256SUMS.txt --clobber

src/PlanViewer.App/PlanViewer.App.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<Nullable>enable</Nullable>
66
<ApplicationManifest>app.manifest</ApplicationManifest>
77
<AvaloniaUseCompiledBindingsByDefault>true</AvaloniaUseCompiledBindingsByDefault>
8-
<Version>0.7.0</Version>
8+
<Version>0.8.0</Version>
99
<Authors>Erik Darling</Authors>
1010
<Company>Darling Data LLC</Company>
1111
<Product>Performance Studio</Product>

src/PlanViewer.Cli/PlanViewer.Cli.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@
1111
<Nullable>enable</Nullable>
1212
<RootNamespace>PlanViewer.Cli</RootNamespace>
1313
<AssemblyName>planview</AssemblyName>
14-
<Version>0.5.0</Version>
14+
<Version>0.8.0</Version>
1515
<Authors>Erik Darling</Authors>
1616
<Company>Darling Data LLC</Company>
17-
<Product>SQL Performance Studio</Product>
17+
<Product>Performance Studio</Product>
1818
<Copyright>Copyright (c) 2026 Erik Darling, Darling Data LLC</Copyright>
1919
</PropertyGroup>
2020

0 commit comments

Comments
 (0)