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
27 changes: 18 additions & 9 deletions .github/workflows/build-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,39 +12,48 @@ on:
default: false
type: boolean

concurrency:
group: release
cancel-in-progress: false
Comment thread
guitarrapc marked this conversation as resolved.

jobs:
validate-release:
permissions:
contents: read
uses: Cysharp/Actions/.github/workflows/validate-release.yaml@main
with:
tag: ${{ inputs.tag }}

update-packagejson:
needs: [validate-release]
name: Update package.json
permissions:
actions: read
contents: write
uses: Cysharp/Actions/.github/workflows/update-packagejson.yaml@main
with:
file-path: ./src/YetAnotherHttpHandler/package.json
tag: ${{ inputs.tag }}
tag: ${{ needs.validate-release.outputs.tag }}
dry-run: ${{ inputs.dry-run }}

# release
create-release:
needs: [validate-release, update-packagejson]
name: Create Release
needs: [update-packagejson]
permissions:
contents: write
id-token: write # required for NuGet Trusted Publish
uses: Cysharp/Actions/.github/workflows/create-release.yaml@main
with:
commit-id: ${{ needs.update-packagejson.outputs.sha }}
dry-run: ${{ inputs.dry-run }}
tag: ${{ inputs.tag }}
nuget-push: false
release-upload: false
release-format: '{0}'
tag: ${{ needs.validate-release.outputs.tag }}
release-format: "{0}"
secrets: inherit

cleanup:
name: Cleanup package.json branch
if: ${{ needs.update-packagejson.outputs.is-branch-created == 'true' }}
needs: [update-packagejson]
if: ${{ always() && needs.update-packagejson.outputs.is-branch-created == 'true' }}
needs: [update-packagejson, create-release]
permissions:
contents: write
uses: Cysharp/Actions/.github/workflows/clean-packagejson-branch.yaml@main
Expand Down
Loading