Repository navigation
Expand file tree
/
Copy pathdispatch_master_to_develop.yaml
More file actions
65 lines (56 loc) · 1.79 KB
/
Copy pathdispatch_master_to_develop.yaml
File metadata and controls
65 lines (56 loc) · 1.79 KB
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
name: "[Dispatch] Master To Develop"
on:
workflow_dispatch:
inputs:
version:
description: 'enter version(x.y.z)'
required: true
default: '2.0.0'
env:
VERSION: ${{ github.event.inputs.version }}
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
REF_BRANCH: "master"
jobs:
merge_to_develop:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: ${{env.REF_BRANCH}}
fetch-depth: 0
fetch-tags: false
submodules: true
token: ${{ secrets.PAT_TOKEN }}
- name: Fetch develop branch
run: |
git checkout -b develop origin/develop
- name: Configure git
run: |
git log -n 10 --oneline
git branch
git config --global user.email "${{ vars.GIT_EMAIL }}"
git config --global user.name "${{ vars.GIT_USERNAME }}"
- name: Import GPG key
id: import-gpg
uses: crazy-max/ghaction-import-gpg@v6.2.0
with:
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
passphrase: ${{ secrets.GPG_PASSPHRASE }}
git_user_signingkey: true
git_commit_gpgsign: true
- name: Merge master into develop
run: |
git merge --no-ff master -m "chore: merge master into develop after ${{ env.VERSION }} version tagging"
- name: Push changes to develop using GitHub push action
uses: ad-m/github-push-action@v0.6.0
with:
branch: develop
github_token: ${{ secrets.PAT_TOKEN }}
- name: Notice when job fails
if: failure()
uses: 8398a7/action-slack@v3.15.0
with:
status: ${{job.status}}
fields: repo,workflow,job
author_name: Github Action Slack