Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
16 commits
Select commit Hold shift + click to select a range
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
80 changes: 80 additions & 0 deletions .github/workflows/build-and-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
name: Build and Release

on:
push:
tags:
- 'v*'
workflow_dispatch:

permissions:
contents: write

jobs:
build:
name: Build ${{ matrix.rid }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- rid: win-x64
artifact_name: Ink-Canvas-Next-win-x64
output_name: Ink-Canvas-Next-win-x64
# - rid: linux-x64
# artifact_name: Ink-Canvas-Next-linux-x64
# output_name: Ink-Canvas-Next-linux-x64

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: '10.0.x'

- name: Restore
run: dotnet restore "Ink Canvas Next.slnx"

- name: Test
run: dotnet test "Ink Canvas Next.slnx" --configuration Release --no-restore

- name: Publish
run: |
dotnet publish Ink-Canvas-Next/Ink-Canvas-Next.csproj \
--configuration Release \
--runtime ${{ matrix.rid }} \
--self-contained false \
-p:PublishSingleFile=true \
-p:IncludeNativeLibrariesForSelfExtract=true \
-o publish/${{ matrix.output_name }}

- name: Archive package
run: |
cd publish
tar -czf ${{ matrix.output_name }}.tar.gz ${{ matrix.output_name }}

- name: Upload build artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.artifact_name }}
path: publish/${{ matrix.output_name }}.tar.gz

release:
name: Create GitHub Release
runs-on: ubuntu-latest
needs: build
if: startsWith(github.ref, 'refs/tags/v')

steps:
- name: Download artifacts
uses: actions/download-artifact@v4
with:
path: release-assets

- name: Create release
uses: softprops/action-gh-release@v2
with:
generate_release_notes: true
files: |
release-assets/**/*.tar.gz
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -423,3 +423,4 @@ FodyWeavers.xsd
.kiro/
.vscode/
.idea/
.workbuddy/
37 changes: 0 additions & 37 deletions Ink-Canvas-Next.Tests/AvaloniaTestCollection.cs

This file was deleted.

32 changes: 0 additions & 32 deletions Ink-Canvas-Next.Tests/Ink-Canvas-Next.Tests.csproj

This file was deleted.

192 changes: 0 additions & 192 deletions Ink-Canvas-Next.Tests/Services/CanvasServicePropertyTests.cs

This file was deleted.

Loading
Loading