2024-03-03 13:11:25 -08:00
|
|
|
name: Continuous Integration
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
2024-03-04 20:07:15 -08:00
|
|
|
- master
|
2024-03-03 13:11:25 -08:00
|
|
|
pull_request:
|
2024-03-04 20:07:15 -08:00
|
|
|
branches: [master]
|
|
|
|
workflow_dispatch:
|
2024-03-03 13:11:25 -08:00
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
name: Build
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
include:
|
|
|
|
- os: ubuntu-latest
|
|
|
|
platform: linux-x64
|
|
|
|
- os: windows-latest
|
|
|
|
platform: win-x64
|
|
|
|
- os: macos-latest
|
|
|
|
platform: osx-x64
|
|
|
|
- os: macos-latest
|
|
|
|
platform: osx-arm64
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
steps:
|
|
|
|
- name: Checkout sources
|
|
|
|
uses: actions/checkout@v4
|
|
|
|
with:
|
|
|
|
fetch-depth: 0
|
|
|
|
- name: Setup .NET
|
|
|
|
uses: actions/setup-dotnet@v4
|
|
|
|
with:
|
|
|
|
dotnet-version: 8.0.x
|
|
|
|
- name: Build
|
|
|
|
run: dotnet build -c Release
|
|
|
|
- name: Publish
|
2024-03-03 13:28:48 -08:00
|
|
|
run: dotnet publish src/SourceGit.csproj -c Release -o publish -r ${{ matrix.platform }} -p:PublishAot=true -p:PublishTrimmed=true -p:TrimMode=link --self-contained
|
2024-03-03 13:22:26 -08:00
|
|
|
- name: Upload Artifact
|
|
|
|
uses: actions/upload-artifact@v4
|
|
|
|
with:
|
|
|
|
name: ${{ matrix.platform }}
|
|
|
|
path: publish
|