Added release notes for versons 2.0...3.0. (#544)
#1
Workflow file for this run
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: publish to NuGet | |
| on: | |
| push: | |
| tags: | |
| - 'releases/*' | |
| env: | |
| DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1 | |
| DOTNET_NOLOGO: true | |
| SLEEP_DURATION: 60 | |
| jobs: | |
| publish: | |
| runs-on: ubuntu-22.04 | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| with: | |
| # This is necessary so that we have the tags. | |
| fetch-depth: 0 | |
| - name: Set Build Version | |
| run: | | |
| $version = "$env:GITHUB_REF_NAME".Substring("releases/".Length) | |
| $File = ( | |
| Select-Xml -XPath "/Project/PropertyGroup[@Label='NuGet']/Version" -Path "Directory.Build.props" | |
| )[0].Node | |
| $File.InnerText = $version | |
| $File.OwnerDocument.Save((Join-Path $PWD.ProviderPath Directory.Build.props)) | |
| echo "VERSION=$version" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append | |
| shell: pwsh | |
| - name: Add version to global.json | |
| run: | | |
| $version = "9.0.307" | |
| $globalJsonPath = "global.json" | |
| $globalJson = Get-Content -Raw -Path $globalJsonPath | ConvertFrom-Json | |
| if ($null -eq $globalJson.sdk.version) { | |
| $globalJson.sdk | Add-Member -Type NoteProperty -Name version -Value $version | |
| } else { | |
| $globalJson.sdk.version = $version | |
| } | |
| $globalJson | ConvertTo-Json -Depth 10 | Set-Content -Path $globalJsonPath | |
| shell: pwsh | |
| - name: Install .NET Core | |
| uses: actions/setup-dotnet@v5 | |
| with: | |
| dotnet-version: 9.0.304 | |
| - name: Install local tools | |
| run: dotnet tool restore | |
| - name: Run integration tests | |
| run: dotnet run --project build/Build.fsproj | |
| - name: Pack FSharp.Data.GraphQL.Shared project | |
| run: | | |
| cd src/FSharp.Data.GraphQL.Shared | |
| dotnet pack --no-build --configuration Release /p:IsNuGet=true -o ../../nuget | |
| - name: Publish FSharp.Data.GraphQL.Shared package to NuGet | |
| run: | | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Shared.${{env.VERSION}}.nupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| # wait for the package to be available | |
| sleep ${{env.SLEEP_DURATION}} | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Shared.${{env.VERSION}}.snupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| - name: Pack FSharp.Data.GraphQL.Client project | |
| run: | | |
| cd src/FSharp.Data.GraphQL.Client | |
| dotnet pack --configuration Release /p:IsNuGet=true -o ../../nuget | |
| - name: Publish FSharp.Data.GraphQL.Client package to NuGet | |
| run: | | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Client.${{env.VERSION}}.nupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Client.${{env.VERSION}}.snupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| - name: Pack FSharp.Data.GraphQL.Server project | |
| run: | | |
| cd src/FSharp.Data.GraphQL.Server | |
| dotnet pack --no-build --configuration Release /p:IsNuGet=true -o ../../nuget | |
| - name: Publish FSharp.Data.GraphQL.Server package to NuGet | |
| run: | | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Server.${{env.VERSION}}.nupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Server.${{env.VERSION}}.snupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| - name: Pack FSharp.Data.GraphQL.Server.AspNetCore project | |
| run: | | |
| cd src/FSharp.Data.GraphQL.Server.AspNetCore | |
| dotnet pack --no-build --configuration Release /p:IsNuget=true -o ../../nuget | |
| - name: Publish FSharp.Data.GraphQL.Server.AspNetCore package to NuGet | |
| run: | | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Server.AspNetCore.${{env.VERSION}}.nupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Server.AspNetCore.${{env.VERSION}}.snupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| - name: Pack FSharp.Data.GraphQL.Server.Giraffe project | |
| run: | | |
| cd src/FSharp.Data.GraphQL.Server.Giraffe | |
| dotnet pack --no-build --configuration Release /p:IsNuget=true -o ../../nuget | |
| - name: Publish FSharp.Data.GraphQL.Server.Giraffe package to NuGet | |
| run: | | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Server.Giraffe.${{env.VERSION}}.nupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Server.Giraffe.${{env.VERSION}}.snupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| - name: Pack FSharp.Data.GraphQL.Server.Oxpecker project | |
| run: | | |
| cd src/FSharp.Data.GraphQL.Server.Oxpecker | |
| dotnet pack --no-build --configuration Release /p:IsNuget=true -o ../../nuget | |
| - name: Publish FSharp.Data.GraphQL.Server.Oxpecker package to NuGet | |
| run: | | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Server.Oxpecker.${{env.VERSION}}.nupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Server.Oxpecker.${{env.VERSION}}.snupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| - name: Pack FSharp.Data.GraphQL.Server.Relay project | |
| run: | | |
| cd src/FSharp.Data.GraphQL.Server.Relay | |
| dotnet pack --no-build --configuration Release /p:IsNuGet=true -o ../../nuget | |
| - name: Publish FSharp.Data.GraphQL.Server.Relay package to NuGet | |
| run: | | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Server.Relay.${{env.VERSION}}.nupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Server.Relay.${{env.VERSION}}.snupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| - name: Pack FSharp.Data.GraphQL.Server.Middleware project | |
| run: | | |
| cd src/FSharp.Data.GraphQL.Server.Middleware | |
| dotnet pack --no-build --configuration Release /p:IsNuGet=true -o ../../nuget | |
| - name: Publish FSharp.Data.GraphQL.Server.Middleware package to NuGet | |
| run: | | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Server.Middleware.${{env.VERSION}}.nupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| dotnet nuget push nuget/FSharp.Data.GraphQL.Server.Middleware.${{env.VERSION}}.snupkg -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| - name: Prepare the sample project to be packed as a project template | |
| run: | | |
| & "./Prepare template project for packing.ps1" | |
| shell: pwsh | |
| - name: Pack FSharp.Data.GraphQL.ProjectTemplates template project | |
| run: | | |
| cd samples | |
| dotnet pack --configuration Release -o ../nuget | |
| - name: Publish FSharp.Data.GraphQL.ProjectTemplates package to NuGet | |
| run: | | |
| $path = "nuget/FSharp.Data.GraphQL.ProjectTemplates.${{env.VERSION}}.nupkg" | |
| dotnet nuget push $path -k ${{secrets.NUGET_SECRET}} --skip-duplicate | |
| shell: pwsh |