-
Notifications
You must be signed in to change notification settings - Fork 90
79 lines (68 loc) · 2.19 KB
/
deploy.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
69
70
71
72
73
74
75
76
77
78
79
name: Deploy
on:
pull_request: # Run workflow on PRs to the develop branch
branches:
- develop
workflow_dispatch:
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v4.1.7
with:
submodules: false
lfs: false
# - name: Detect API Change
# id: changed-api
# uses: tj-actions/changed-files@v43
# with:
# # Avoid using single or double quotes for multiline patterns
# files: |
# src/coreComponents/schema/**/*.{xsd,rst}
# - name: Run step if test file(s) change
# if: steps.changed-api.outputs.any_changed == 'true'
# env:
# BUMP_BEHAVIOR: "major"
# run: |
# echo "Must be a major change"
- name: Get Next Version
id: semver
uses: ietf-tools/semver-action@v1.8.0
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: develop
noVersionBumpBehavior: patch
- name: Create Draft Release
uses: ncipollo/release-action@v1.14.0
with:
prerelease: true
draft: false
commit: ${{ github.sha }}
tag: ${{ steps.semver.outputs.nextStrict }}
name: ${{ steps.semver.outputs.nextStrict }}
body: '*pending*'
token: ${{ secrets.GITHUB_TOKEN }}
- name: Update CHANGELOG
id: changelog
uses: requarks/changelog-action@v1.10.2
with:
token: ${{ github.token }}
fromTag: ${{ steps.semver.outputs.nextStrict }}
toTag: ${{ steps.semver.outputs.current }}
excludeTypes: ''
writeToFile: false
- name: Extract docker image tag
id: extract_docker_image_tag
run: |
echo "${{ steps.changelog.outputs.changes }}"
- name: Create Release
uses: ncipollo/release-action@v1.14.0
with:
allowUpdates: true
makeLatest: true
draft: false
tag: ${{ steps.semver.outputs.nextStrict }}
name: ${{ steps.semver.outputs.nextStrict }}
body: ${{ steps.changelog.outputs.changes }}
token: ${{ secrets.GITHUB_TOKEN }}