Adding support for WPF #84
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build | |
| on: | |
| push: | |
| branches: [ "main" ] | |
| pull_request: | |
| branches: [ "main" ] | |
| jobs: | |
| git-version: | |
| runs-on: windows-latest | |
| outputs: | |
| SemVer: ${{ steps.gitversion.outputs.semVer }} | |
| AssemblySemVer: ${{ steps.gitversion.outputs.AssemblySemVer }} | |
| InformationalVersion: ${{ steps.gitversion.outputs.InformationalVersion }} | |
| NuGetVersion: ${{ steps.gitversion.outputs.NuGetVersion }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-tags: 'true' | |
| fetch-depth: 0 | |
| - name: Install GitVersion | |
| uses: gittools/actions/gitversion/setup@v1.1.1 | |
| with: | |
| versionSpec: '5.x' | |
| preferLatestVersion: true | |
| - name: GitVersion Execute | |
| id: gitversion | |
| uses: gittools/actions/gitversion/execute@v1.1.1 | |
| with: | |
| useConfigFile: true | |
| configFilePath: 'GitVersion.yml' | |
| build-maui: | |
| runs-on: windows-latest | |
| needs: git-version | |
| env: | |
| SemVer: ${{ needs.git-version.outputs.SemVer }} | |
| AssemblySemVer: ${{ needs.git-version.outputs.AssemblySemVer }} | |
| InformationalVersion: ${{ needs.git-version.outputs.InformationalVersion }} | |
| NuGetVersion: ${{ needs.git-version.outputs.NuGetVersion }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-tags: 'true' | |
| fetch-depth: 0 | |
| - name: Display version | |
| run: | | |
| echo SemVer: ${{ env.SemVer }} | |
| echo AssemblySemVer: ${{ env.AssemblySemVer }} | |
| echo InformationalVersion: ${{ env.InformationalVersion }} | |
| echo NuGetVersion: ${{ env.NuGetVersion }} | |
| - name: Install .NET 9 | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: 9.0.x | |
| - name: Install MAUI | |
| run: dotnet workload install maui --source https://api.nuget.org/v3/index.json | |
| ## Build for MAUI | |
| - name: Build | |
| run: dotnet build ${{ github.workspace }}\Naveasy\Naveasy.csproj --configuration Release /p:Version=${{ env.SemVer }} /p:AssemblyVersion=${{ env.AssemblySemVer }} /p:InformationalVersion=${{ env.InformationalVersion }} | |
| - name: Pack | |
| run: dotnet pack ${{ github.workspace }}\Naveasy\Naveasy.csproj --configuration release --no-build --output packages /p:PackageVersion=${{ env.NuGetVersion }} | |
| - name: Push | |
| ##if: github.ref == 'refs/heads/main' | |
| run: dotnet nuget push ${{ github.workspace }}\packages\Naveasy.*.nupkg --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_API_KEY }} | |
| build-wpf: | |
| runs-on: windows-latest | |
| needs: git-version | |
| env: | |
| SemVer: ${{ needs.git-version.outputs.SemVer }} | |
| AssemblySemVer: ${{ needs.git-version.outputs.AssemblySemVer }} | |
| InformationalVersion: ${{ needs.git-version.outputs.InformationalVersion }} | |
| NuGetVersion: ${{ needs.git-version.outputs.NuGetVersion }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-tags: 'true' | |
| fetch-depth: 0 | |
| - name: Display version | |
| run: | | |
| echo SemVer: ${{ env.SemVer }} | |
| echo AssemblySemVer: ${{ env.AssemblySemVer }} | |
| echo InformationalVersion: ${{ env.InformationalVersion }} | |
| echo NuGetVersion: ${{ env.NuGetVersion }} | |
| - name: Install .NET 9 | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: 9.0.x | |
| ## Build for WPF | |
| - name: Build | |
| run: dotnet build ${{ github.workspace }}\Naveasy.WPF\Naveasy.WPF.csproj --configuration Release /p:Version=${{ env.SemVer }} /p:AssemblyVersion=${{ env.AssemblySemVer }} /p:InformationalVersion=${{ env.InformationalVersion }} | |
| - name: Pack | |
| run: dotnet pack ${{ github.workspace }}\Naveasy.WPF\Naveasy.WPF.csproj --configuration release --no-build --output packages.wpf /p:PackageVersion=${{ env.NuGetVersion }} | |
| - name: Push | |
| ##if: github.ref == 'refs/heads/main' | |
| run: dotnet nuget push ${{ github.workspace }}\packages.wpf\Naveasy.WPF.*.nupkg --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_API_KEY }} |