-
Notifications
You must be signed in to change notification settings - Fork 125
68 lines (59 loc) · 1.76 KB
/
cd.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
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-preview-packages:
uses: ./.github/workflows/publish.yml
needs: [ continuous-integration ]
with:
environment: preview
secrets: inherit
publish-release-packages:
uses: ./.github/workflows/publish.yml
needs: [ publish-preview-packages ]
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/[email protected]
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}}'