Skip to content

Fix the .net 8 build #653

Fix the .net 8 build

Fix the .net 8 build #653

Workflow file for this run

name: dev-build
#this drops to github with beta tag?
on:
push:
branches: [ dev]
pull_request:
branches: [ dev, main ]
workflow_dispatch:
jobs:
build:
name: Build Comet-Nuget
env:
NUPKG_MAJOR: 0.2
BASE: 334
runs-on: windows-2022
steps:
- uses: actions/checkout@v2
with:
submodules: true
- uses: actions/setup-java@v2
with:
distribution: 'zulu' # See 'Supported distributions' for available options
java-version: '11'
- name: install .NET
shell: pwsh
run: |
$ProgressPreference = 'SilentlyContinue'
Invoke-WebRequest -Uri "https://dot.net/v1/dotnet-install.ps1" -OutFile dotnet-install.ps1
& .\dotnet-install.ps1 -InstallDir "$env:ProgramFiles\dotnet\" -Verbose -Channel STS
& dotnet --list-sdks
# - name: Install Visual Studio Preview
# shell: pwsh
# run: powershell .\build\install-vs.ps1
- name: Add msbuild to PATH
uses: microsoft/setup-msbuild@v1.1
with:
vs-prerelease: true
- name: Install Maui Workload
shell: pwsh
run: |
& dotnet workload install maui `
--skip-sign-check `
- name: Restore Comet-Nuget.sln
run: msbuild /r build/Comet-Nuget.sln
- name: Build Comet-Nuget.sln
run: MSBuild build/Comet-Nuget.sln
- name: Nuget Pack step
shell: bash
run: |
MINOR_VERSION=$(( $BASE + $GITHUB_RUN_NUMBER ))
VERSION=0.3.$MINOR_VERSION-alpha
echo "PACKAGE VERSION: $VERSION"
nuget pack Comet.nuspec -version $VERSION -Symbols -SymbolPackageFormat snupkg
- name: Nuget Pack Template step
shell: bash
run: |
MINOR_VERSION=$(( $BASE + $GITHUB_RUN_NUMBER ))
VERSION=0.3.$MINOR_VERSION-alpha
echo "PACKAGE VERSION: $VERSION"
nuget pack "templates\comet-templates.nuspec" -version $VERSION
- uses: actions/upload-artifact@v2
name: Upload Nuget Artifact
with:
name: nuget-artifact.${{env.GITHUB_RUN_NUMBER}}
path: |
**\*.nupkg
**\*.snupkg
**\*.symbols.nupkg
# - name: Restore Comet-Tests.sln
# run: nuget restore build/Comet-Tests.sln
# - name: Build Tests Project
# run: msbuild tests/Comet.Tests/Comet.Tests.csproj /p:Configuration=Release
# - name: Run Tests Project
# run: dotnet test tests/Comet.Tests/Comet.Tests.csproj