Skip to content

Commit 0a94b80

Browse files
Update workflows [skip ci]
1 parent 8458e7e commit 0a94b80

File tree

2 files changed

+9
-12
lines changed

2 files changed

+9
-12
lines changed

.github/workflows/development-publish.yml

+1-5
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,9 @@
11
name: Publish development branch on Merge
22

33
on:
4-
pull_request:
5-
types:
6-
- closed
4+
push:
75
branches:
86
- development
9-
# Ignore PRs targetting main
107

118
# Allows you to run this workflow manually from the Actions tab
129
workflow_dispatch:
@@ -17,7 +14,6 @@ concurrency:
1714

1815
jobs:
1916
release_on_merge:
20-
if: github.event.pull_request.merged == true
2117
name: Tag and Publish UPM package
2218
uses: realitycollective/reusableworkflows/.github/workflows/upversionandtagrelease.yml@v2
2319
with:

.github/workflows/main-publish.yml

+8-7
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,17 @@
11
name: Publish main branch and increment version
22

33
on:
4-
pull_request:
5-
types:
6-
- closed
4+
push:
75
branches:
86
- main
97

8+
# Allows you to run this workflow manually from the Actions tab, last resort if GitHub does not behave
9+
workflow_dispatch:
10+
1011
jobs:
1112
# Get Version to tag and release the branch, no up-version - [no-ver] included in PR title
1213
validate-environment:
13-
if: github.event.pull_request.merged == true && contains(github.event.pull_request.title, 'no-ver')
14+
if: contains(github.event.head_commit.message, 'no-ver')
1415
name: Get Version from UPM package
1516
uses: realitycollective/reusableworkflows/.github/workflows/getpackageversionfrompackage.yml@v2
1617
with:
@@ -28,7 +29,7 @@ jobs:
2829

2930
# Up version the release and publish major release
3031
upversion-major-Package:
31-
if: github.event.pull_request.merged == true && contains(github.event.pull_request.title, 'no-ver') == false && contains(github.event.pull_request.title, 'major-release')
32+
if: contains(github.event.head_commit.message, 'no-ver') == false && contains(github.event.head_commit.message, 'major-release')
3233
name: Major Version package and release
3334
uses: realitycollective/reusableworkflows/.github/workflows/upversionandtagrelease.yml@v2
3435
with:
@@ -38,7 +39,7 @@ jobs:
3839

3940
# Up version the release and publish minor release
4041
upversion-minor-Package:
41-
if: github.event.pull_request.merged == true && contains(github.event.pull_request.title, 'no-ver') == false && contains(github.event.pull_request.title, 'minor-release')
42+
if: contains(github.event.head_commit.message, 'no-ver') == false && contains(github.event.head_commit.message, 'minor-release')
4243
name: Minor Version package and release
4344
uses: realitycollective/reusableworkflows/.github/workflows/upversionandtagrelease.yml@v2
4445
with:
@@ -48,7 +49,7 @@ jobs:
4849

4950
# Up version the release and publish patch release (default)
5051
upversion-patch-Package:
51-
if: github.event.pull_request.merged == true && contains(github.event.pull_request.title, 'no-ver') == false && contains(github.event.pull_request.title, 'minor-release') == false && contains(github.event.pull_request.title, 'major-release') == false
52+
if: contains(github.event.head_commit.message, 'no-ver') == false && contains(github.event.head_commit.message, 'minor-release') == false && contains(github.event.head_commit.message, 'major-release') == false
5253
name: Patch Version package and release
5354
uses: realitycollective/reusableworkflows/.github/workflows/upversionandtagrelease.yml@v2
5455
with:

0 commit comments

Comments
 (0)