Publish pipeline after push by @TylerBrinks #28
This file contains 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: continuous-delivery | |
run-name: Publish pipeline after ${{github.event_name}} by @${{ github.actor }} | |
on: | |
push: | |
branches: | |
- release/** | |
jobs: | |
continuous-integration: | |
uses: ./.github/workflows/build.yml | |
with: | |
pack: true | |
secrets: inherit | |
publish-release-packages: | |
uses: ./.github/workflows/publish.yml | |
needs: [ continuous-integration ] | |
with: | |
environment: release | |
secrets: inherit | |
tag-and-release: | |
runs-on: ubuntu-latest | |
needs: [ publish-release-packages ] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Semantic version | |
uses: './.github/actions/dotnet/version' | |
id: version | |
- name: Create tag | |
uses: rickstaa/action-create-tag@v1 | |
id: tag | |
with: | |
tag: 'v${{steps.version.outputs.release-version}}' | |
tag_exists_error: true | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Create pull request | |
uses: devops-infra/action-pull-request@v0.5.5 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
target_branch: master | |
title: Release v${{steps.version.outputs.release-version}} | |
draft: false | |
get_diff: true | |
ignore_users: "dependabot" | |
allow_no_diff: true | |
- name: Create the release | |
uses: ncipollo/release-action@v1 | |
with: | |
allowUpdates: true | |
generateReleaseNotes: true | |
name: 'v${{steps.version.outputs.release-version}}' | |
tag: 'v${{steps.version.outputs.release-version}}' |