Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,14 @@ on:
description: Existing published release tag to recover
required: true
type: string
recovery_mode:
description: Work to run for an existing release
required: true
default: full
type: choice
options:
- full
- nuget

concurrency:
group: ${{ github.workflow }}-${{ github.event.release.tag_name || inputs.tag_name }}
Expand Down Expand Up @@ -142,6 +150,7 @@ jobs:

build-artifacts:
name: Artifacts (${{ matrix.name }})
if: ${{ github.event_name != 'workflow_dispatch' || inputs.recovery_mode == 'full' }}
needs: validate-release
runs-on: ${{ matrix.os }}
timeout-minutes: 30
Expand Down Expand Up @@ -258,6 +267,7 @@ jobs:

package-nuget:
name: Package NuGet
if: ${{ !cancelled() && needs.validate-release.result == 'success' && (needs.build-artifacts.result == 'success' || (github.event_name == 'workflow_dispatch' && inputs.recovery_mode == 'nuget')) }}
needs: [validate-release, build-artifacts]
runs-on: ubuntu-latest
permissions:
Expand Down Expand Up @@ -432,7 +442,8 @@ jobs:
with:
name: surge-net-nuget
path: nupkgs
- name: Verify immutable package handoff
- id: verify_package
name: Verify immutable package handoff
env:
EXPECTED_PACKAGE_NAME: ${{ needs.package-nuget.outputs.package_name }}
EXPECTED_PACKAGE_SHA256: ${{ needs.package-nuget.outputs.package_sha256 }}
Expand Down Expand Up @@ -468,10 +479,12 @@ jobs:
--api-key "${NUGET_API_KEY}" \
--skip-duplicate
- name: Push to GitHub Packages
if: ${{ !cancelled() && steps.verify_package.outcome == 'success' }}
run: dotnet nuget push "nupkgs/${{ needs.package-nuget.outputs.package_name }}" --source https://nuget.pkg.github.com/fintermobilityas/index.json --api-key ${{ secrets.GITHUB_TOKEN }} --skip-duplicate

publish-cargo-crates-io:
name: Publish Cargo (crates.io)
if: ${{ github.event_name != 'workflow_dispatch' || inputs.recovery_mode == 'full' }}
needs: [validate-release, build-artifacts]
runs-on: ubuntu-latest
env:
Expand All @@ -498,6 +511,7 @@ jobs:

upload-release-assets:
name: Upload Release Assets
if: ${{ github.event_name != 'workflow_dispatch' || inputs.recovery_mode == 'full' }}
needs: [validate-release, build-artifacts, package-nuget]
runs-on: ubuntu-latest
permissions:
Expand Down