Skip to content

Update build.yml

Update build.yml #37

Workflow file for this run

name: JishoTangoAssistant Build
on:
push:
branches:
- "master"
paths-ignore:
- ".github/**"
- "!.github/workflows/build.yml"
- ".gitignore"
- ".gitattributes"
- "LICENSE"
- "README.md"
pull_request:
branches:
- "master"
paths-ignore:
- ".github/**"
- "!.github/workflows/build.yml"
- ".gitignore"
- ".gitattributes"
- "LICENSE"
- "README.md"
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ "ubuntu-latest", "windows-latest" ]
dotnet-version: ['8.0']
steps:
- uses: actions/checkout@v4
- name: Setup .NET Core SDK ${{ matrix.dotnet-version }}
uses: actions/setup-dotnet@v4
with:
dotnet-version: ${{ matrix.dotnet-version }}
- name: Install dependencies
run: dotnet restore
- name: Build
run: dotnet build JishoTangoAssistant --no-restore --configuration Release --property:OutputPath=build/JishoTangoAssistant
- name: Test
run: dotnet test --no-restore --configuration Release --verbosity normal --property:TestResultsDirectory=build/tests
- name: Packaging workflow data as artifacts
run: mkdir deploy && cp -r JishoTangoAssistant/build/JishoTangoAssistant deploy/ && ls ./deploy/JishoTangoAssistant
- name: Upload to artifact (Windows)
uses: actions/upload-artifact@v4
with:
name: JishoTangoAssistant-${{ matrix.os }}
path: |
./deploy/JishoTangoAssistant/**
!./deploy/JishoTangoAssistant/runtimes/browser-wasm
!./deploy/JishoTangoAssistant/runtimes/linux-arm
!./deploy/JishoTangoAssistant/runtimes/linux-arm64
!./deploy/JishoTangoAssistant/runtimes/linux-armel
!./deploy/JishoTangoAssistant/runtimes/linux-mips64
!./deploy/JishoTangoAssistant/runtimes/linux-musl-arm
!./deploy/JishoTangoAssistant/runtimes/linux-musl-arm64
!./deploy/JishoTangoAssistant/runtimes/linux-ppc64le
!./deploy/JishoTangoAssistant/runtimes/linux-s390x
!./deploy/JishoTangoAssistant/runtimes/linux-x64
!./deploy/JishoTangoAssistant/runtimes/linux-x86
!./deploy/JishoTangoAssistant/runtimes/maccatalyst-arm64
!./deploy/JishoTangoAssistant/runtimes/maccatalyst-x64
!./deploy/JishoTangoAssistant/runtimes/osx
!./deploy/JishoTangoAssistant/runtimes/osx-arm64
!./deploy/JishoTangoAssistant/runtimes/osx-x64
!./deploy/JishoTangoAssistant/runtimes/browser-wasm/**
!./deploy/JishoTangoAssistant/runtimes/linux-arm/**
!./deploy/JishoTangoAssistant/runtimes/linux-arm64/**
!./deploy/JishoTangoAssistant/runtimes/linux-armel/**
!./deploy/JishoTangoAssistant/runtimes/linux-mips64/**
!./deploy/JishoTangoAssistant/runtimes/linux-musl-arm/**
!./deploy/JishoTangoAssistant/runtimes/linux-musl-arm64/**
!./deploy/JishoTangoAssistant/runtimes/linux-ppc64le/**
!./deploy/JishoTangoAssistant/runtimes/linux-s390x/**
!./deploy/JishoTangoAssistant/runtimes/linux-x64/**
!./deploy/JishoTangoAssistant/runtimes/linux-x86/**
!./deploy/JishoTangoAssistant/runtimes/maccatalyst-arm64/**
!./deploy/JishoTangoAssistant/runtimes/maccatalyst-x64/**
!./deploy/JishoTangoAssistant/runtimes/osx/**
!./deploy/JishoTangoAssistant/runtimes/osx-arm64/**
!./deploy/JishoTangoAssistant/runtimes/osx-x64/**
if: matrix.os == 'windows-latest'
- name: Upload to artifact (Linux)
uses: actions/upload-artifact@v3
with:
name: JishoTangoAssistant-${{ matrix.os }}
path: |
./deploy/JishoTangoAssistant/**
!./deploy/JishoTangoAssistant/runtimes/browser-wasm
!./deploy/JishoTangoAssistant/runtimes/maccatalyst-arm64
!./deploy/JishoTangoAssistant/runtimes/maccatalyst-x64
!./deploy/JishoTangoAssistant/runtimes/osx
!./deploy/JishoTangoAssistant/runtimes/osx-arm64
!./deploy/JishoTangoAssistant/runtimes/osx-x64
!./deploy/JishoTangoAssistant/runtimes/win-arm
!./deploy/JishoTangoAssistant/runtimes/win-arm64
!./deploy/JishoTangoAssistant/runtimes/win-x64
!./deploy/JishoTangoAssistant/runtimes/win-x86
!./deploy/JishoTangoAssistant/runtimes/browser-wasm/**
!./deploy/JishoTangoAssistant/runtimes/maccatalyst-arm64/**
!./deploy/JishoTangoAssistant/runtimes/maccatalyst-x64/**
!./deploy/JishoTangoAssistant/runtimes/osx/**
!./deploy/JishoTangoAssistant/runtimes/osx-arm64/**
!./deploy/JishoTangoAssistant/runtimes/osx-x64/**
!./deploy/JishoTangoAssistant/runtimes/win-arm/**
!./deploy/JishoTangoAssistant/runtimes/win-arm64/**
!./deploy/JishoTangoAssistant/runtimes/win-x64/**
!./deploy/JishoTangoAssistant/runtimes/win-x86/**
if: matrix.os == 'ubuntu-latest'