Skip to content

Commit b3568db

Browse files
Merge pull request #5 from homy-game-studio/update-ci-template
perf(Template): Split ci in jobs
2 parents 4205fc8 + 1a94e3f commit b3568db

File tree

2 files changed

+21
-49
lines changed

2 files changed

+21
-49
lines changed

templates/ci/.github/workflows/ci.yml

Lines changed: 21 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,37 @@
1-
21
name: CI
32
on:
43
push:
54
branches:
65
- master
6+
77
jobs:
8-
release:
9-
name: release
8+
semantic-release:
109
runs-on: ubuntu-latest
1110
steps:
12-
- uses: actions/checkout@v2
11+
- uses: actions/checkout@v3
1312
with:
1413
fetch-depth: 0
14+
- uses: actions/setup-node@v2
15+
with:
16+
node-version: 14
1517
- name: Semantic release
1618
id: semantic
17-
uses: cycjimmy/semantic-release-action@v2
19+
uses: cycjimmy/semantic-release-action@v3
1820
with:
19-
extra_plugins: |
20-
@semantic-release/changelog
21-
@semantic-release/git
22-
branch: master
21+
semantic_version: 17
2322
env:
2423
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
24+
outputs:
25+
new_release_published: ${{ steps.semantic.outputs.new_release_published }}
26+
new_release_version: ${{ steps.semantic.outputs.new_release_version }}
27+
28+
deploy-upm:
29+
needs: semantic-release
30+
runs-on: ubuntu-latest
31+
steps:
32+
- uses: actions/checkout@v3
33+
with:
34+
fetch-depth: 0
2535
- name: Create upm branch
2636
run: |
2737
git branch -d upm &> /dev/null || echo upm branch not found
@@ -38,9 +48,7 @@ jobs:
3848
env:
3949
PKG_ROOT: Assets/Package
4050
- name: Create upm git tag
41-
if: steps.semantic.outputs.new_release_published == 'true'
51+
if: needs.semantic-release.outputs.new_release_published == 'true'
4252
run: |
43-
git tag $TAG upm
53+
git tag ${{ needs.semantic-release.outputs.new_release_version }} upm
4454
git push origin --tags
45-
env:
46-
TAG: ${{ steps.semantic.outputs.new_release_version }}

templates/ci/releaserc.json

Lines changed: 0 additions & 36 deletions
This file was deleted.

0 commit comments

Comments
 (0)