Skip to content

Commit

Permalink
Add Ubuntu, macOS and Windows CI runs
Browse files Browse the repository at this point in the history
  • Loading branch information
Lamparter authored Dec 14, 2024
1 parent edb2c69 commit 1b5d101
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,18 @@ on:
jobs:
build:
name: Build
runs-on: ubuntu-latest
runs-on: matrix.os

strategy:
matrix:
project:
- Riverside.Markup
- Riverside.Markup.CompilerServices
# - Riverside.Markup.Controls
- Riverside.Markup.InteropServices
# Add more projects here as needed
windows_project:
- Riverside.Markup.Controls
os: [windows-latest, ubuntu-latest, macos-latest]

outputs:
normalized_name: ${{ steps.normalize_name.outputs.normalized_name }}
Expand All @@ -38,9 +40,17 @@ jobs:
- name: Build project
run: dotnet build src/${{ matrix.project }}/${{ matrix.project }}.csproj --configuration Release --no-restore

- name: Build project (Windows)
if: matrix.os == 'windows-latest'
run: dotnet build src/${{ matrix.windows_project }}/${{ matrix.windows_project }}.csproj --configuration Release --no-restore

- name: Pack project
run: dotnet pack src/${{ matrix.project }}/${{ matrix.project }}.csproj --configuration Release --no-build -o ./output

- name: Pack project (Windows)
if: matrix.os == 'windows-latest'
run: dotnet pack src/${{ matrix.windows_project }}/${{ matrix.windows_project }}.csproj --configuration Release --no-build -o ./output

- name: Normalize project name
id: normalize_name
run: echo "normalized_name=$(echo src/${{ matrix.project }}/${{ matrix.project }} | tr '/' '-')" >> $GITHUB_ENV
Expand Down

0 comments on commit 1b5d101

Please sign in to comment.