Skip to content

Updates and fix focus issues #36

Updates and fix focus issues

Updates and fix focus issues #36

Workflow file for this run

name: Build
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
release:
types: [ published ]
env:
BuildVersion: "CI.${{ github.run_id }}"
BuildBranch: "${{ github.ref }}"
BuildParameters: "/v:Minimal /p:Configuration=Release Eto.Veldrid.sln"
jobs:
build-windows:
runs-on: windows-latest
env:
PlatformBuildParameters: /p:Platform=Windows
steps:
- uses: actions/checkout@v2
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: '5.0.x'
- uses: actions/cache@v1
with:
path: ~/.nuget/packages
key: ${{ runner.os }}-nuget-${{ hashFiles('**/packages.lock.json') }}
restore-keys: |
${{ runner.os }}-nuget-
- name: Build
run: dotnet build ${{ env.PlatformBuildParameters }} ${{ env.BuildParameters }}
- name: Pack
run: dotnet pack ${{ env.PlatformBuildParameters }} ${{ env.BuildParameters }}
- name: Upload artifacts
uses: actions/upload-artifact@v2
with:
name: nuget
path: artifacts/nuget/**/*.nupkg
build-mac:
runs-on: macos-latest
env:
PlatformBuildParameters: /p:Platform=Mac
steps:
- uses: actions/checkout@v2
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: '5.0.x'
- name: setup-xamarin
uses: maxim-lobanov/setup-xamarin@v1
with:
mono-version: latest
xamarin-mac-version: latest
xcode-version: latest
- uses: actions/cache@v1
with:
path: ~/.nuget/packages
key: ${{ runner.os }}-nuget-${{ hashFiles('**/packages.lock.json') }}
restore-keys: |
${{ runner.os }}-nuget-
- name: Build
run: dotnet build ${{ env.PlatformBuildParameters }} ${{ env.BuildParameters }}
- name: Pack
run: dotnet pack ${{ env.PlatformBuildParameters }} ${{ env.BuildParameters }}
# - name: Upload artifacts
# uses: actions/upload-artifact@v2
# with:
# name: nuget
# path: artifacts/nuget/**/Eto.Veldrid.XamMac2.nupkg
publish:
needs: [ build-windows, build-mac ]
runs-on: ubuntu-latest
if: github.event_name == 'release' && github.event.action == 'published'
steps:
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
- name: Download NuGet Packages
uses: actions/download-artifact@v1
with:
name: nuget
- name: Push packages
run: dotnet nuget push './nuget/**/*.nupkg' --skip-duplicate -s https://api.nuget.org/v3/index.json -k ${{secrets.NUGET_API_KEY}}