Skip to content

Upgrade to Avalonia 11 #236

Upgrade to Avalonia 11

Upgrade to Avalonia 11 #236

Workflow file for this run

name: CI
on:
push:
branches:
- main
pull_request:
env:
VERSION: "1.8.0.${{github.run_number}}"
jobs:
build:
# windows-latest is required due to some resource stuff.
runs-on: windows-latest
steps:
- name: Setup .NET SDK
uses: actions/setup-dotnet@v1.9.0
with:
dotnet-version: '7.0.x'
- name: Checkout Code
uses: actions/checkout@v2
- name: Install dependencies
run: dotnet restore Source/mqttMultimeter.sln
# Build applications
- name: Build win-x86
run: dotnet publish Source/mqttMultimeter.csproj -r win-x86 -p:Configuration=Release -p:PublishSingleFile=true -p:PublishReadyToRun=true -p:IncludeNativeLibrariesForSelfExtract=true --self-contained true -property:Version=${{ env.VERSION }}
- name: Zip win-x86 build
uses: vimtor/action-zip@v1
with:
files: Source/bin/Release/win-x86/publish/
dest: mqttMultimeter-windows-x86.zip
- name: Collect win-x86 artifacts
uses: actions/upload-artifact@v2
with:
name: mqttMultimeter-windows-x86
path: ${{ github.workspace }}/mqttMultimeter-windows-x86.zip
- name: Build win-x64
run: dotnet publish Source/mqttMultimeter.csproj -r win-x64 -p:Configuration=Release -p:PublishSingleFile=true -p:PublishReadyToRun=true -p:IncludeNativeLibrariesForSelfExtract=true --self-contained true -property:Version=${{ env.VERSION }}
- name: Zip win-x64 build
uses: vimtor/action-zip@v1
with:
files: Source/bin/Release/win-x64/publish/
dest: mqttMultimeter-windows-x64.zip
- name: Collect win-x64 artifacts
uses: actions/upload-artifact@v2
with:
name: mqttMultimeter-windows-x64
path: ${{ github.workspace }}/mqttMultimeter-windows-x64.zip
- name: Build win-arm
run: dotnet publish Source/mqttMultimeter.csproj -r win-arm -p:Configuration=Release -p:PublishSingleFile=true -p:PublishReadyToRun=true -p:IncludeNativeLibrariesForSelfExtract=true --self-contained true -property:Version=${{ env.VERSION }}
- name: Zip win-arm build
uses: vimtor/action-zip@v1
with:
files: Source/bin/Release/win-arm/publish/
dest: mqttMultimeter-windows-arm.zip
- name: Collect win-arm artifacts
uses: actions/upload-artifact@v2
with:
name: mqttMultimeter-windows-arm
path: ${{ github.workspace }}/mqttMultimeter-windows-arm.zip
- name: Build win-arm64
run: dotnet publish Source/mqttMultimeter.csproj -r win-arm64 -p:Configuration=Release -p:PublishSingleFile=true -p:PublishReadyToRun=true -p:IncludeNativeLibrariesForSelfExtract=true --self-contained true -property:Version=${{ env.VERSION }}
- name: Zip win-arm64 build
uses: vimtor/action-zip@v1
with:
files: Source/bin/Release/win-arm64/publish/
dest: mqttMultimeter-windows-arm64.zip
- name: Collect win-arm64 artifacts
uses: actions/upload-artifact@v2
with:
name: mqttMultimeter-windows-arm64
path: ${{ github.workspace }}/mqttMultimeter-windows-arm64.zip
- name: Build osx-x64
run: dotnet publish Source/mqttMultimeter.csproj -r osx.12-x64 -p:Configuration=Release -p:PublishSingleFile=true -p:PublishReadyToRun=true -p:IncludeNativeLibrariesForSelfExtract=true -p:IncludeAllContentForSelfExtract=true --self-contained true -property:Version=${{ env.VERSION }}
- name: Zip osx-x64 build
uses: vimtor/action-zip@v1
with:
files: Source/bin/Release/osx.12-x64/publish/
dest: mqttMultimeter-macOS-x64.zip
- name: Collect osx-x64 artifacts
uses: actions/upload-artifact@v2
with:
name: mqttMultimeter-macOS-x64
path: ${{ github.workspace }}/mqttMultimeter-macOS-x64.zip
- name: Build osx-arm64
run: dotnet publish Source/mqttMultimeter.csproj -r osx.12-arm64 -p:Configuration=Release -p:PublishSingleFile=true -p:PublishReadyToRun=true -p:IncludeNativeLibrariesForSelfExtract=true -p:IncludeAllContentForSelfExtract=true --self-contained true -property:Version=${{ env.VERSION }}
- name: Zip osx-arm64 build
uses: vimtor/action-zip@v1
with:
files: Source/bin/Release/osx.12-arm64/publish/
dest: mqttMultimeter-macOS-arm64.zip
- name: Collect osx-arm64 artifacts
uses: actions/upload-artifact@v2
with:
name: mqttMultimeter-macOS-arm64
path: ${{ github.workspace }}/mqttMultimeter-macOS-arm64.zip
- name: Build linux-x64
run: dotnet publish Source/mqttMultimeter.csproj -r linux-x64 -p:Configuration=Release -p:PublishSingleFile=true -p:PublishReadyToRun=true -p:IncludeNativeLibrariesForSelfExtract=true --self-contained true -property:Version=${{ env.VERSION }}
- name: Zip linux-x64 build
uses: vimtor/action-zip@v1
with:
files: Source/bin/Release/linux-x64/publish/
dest: mqttMultimeter-linux-x64.zip
- name: Collect linux-x64 artifacts
uses: actions/upload-artifact@v2
with:
name: mqttMultimeter-linux-x64
path: ${{ github.workspace }}/mqttMultimeter-linux-x64.zip
- name: Build linux-arm
run: dotnet publish Source/mqttMultimeter.csproj -r linux-arm -p:Configuration=Release -p:PublishSingleFile=true -p:PublishReadyToRun=true -p:IncludeNativeLibrariesForSelfExtract=true --self-contained true -property:Version=${{ env.VERSION }}
- name: Zip linux-arm build
uses: vimtor/action-zip@v1
with:
files: Source/bin/Release/linux-arm/publish/
dest: mqttMultimeter-linux-arm.zip
- name: Collect linux-arm artifacts
uses: actions/upload-artifact@v2
with:
name: mqttMultimeter-linux-arm
path: ${{ github.workspace }}/mqttMultimeter-linux-arm.zip
- name: Build linux-arm64
run: dotnet publish Source/mqttMultimeter.csproj -r linux-arm64 -p:Configuration=Release -p:PublishSingleFile=true -p:PublishReadyToRun=true -p:IncludeNativeLibrariesForSelfExtract=true --self-contained true -property:Version=${{ env.VERSION }}
- name: Zip linux-arm64 build
uses: vimtor/action-zip@v1
with:
files: Source/bin/Release/linux-arm64/publish/
dest: mqttMultimeter-linux-arm64.zip
- name: Collect linux-arm artifacts
uses: actions/upload-artifact@v2
with:
name: mqttMultimeter-linux-arm64
path: ${{ github.workspace }}/mqttMultimeter-linux-arm64.zip
# Release Management
- name: Delete release drafts
uses: hugo19941994/delete-draft-releases@v1.0.0
with:
threshold: 1s
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Create Release
uses: softprops/action-gh-release@v1
#if: startsWith(github.ref, 'refs/tags/')
with:
draft: true
tag_name: v${{ env.VERSION }}
generate_release_notes: true
files: |
${{ github.workspace }}/mqttMultimeter-windows-x86.zip
${{ github.workspace }}/mqttMultimeter-windows-x64.zip
${{ github.workspace }}/mqttMultimeter-windows-arm.zip
${{ github.workspace }}/mqttMultimeter-windows-arm64.zip
${{ github.workspace }}/mqttMultimeter-macOS-x64.zip
${{ github.workspace }}/mqttMultimeter-macOS-arm64.zip
${{ github.workspace }}/mqttMultimeter-linux-x64.zip
${{ github.workspace }}/mqttMultimeter-linux-arm.zip
${{ github.workspace }}/mqttMultimeter-linux-arm64.zip