-
Notifications
You must be signed in to change notification settings - Fork 0
45 lines (45 loc) · 1.27 KB
/
release.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
name: Release Next Version
on:
workflow_dispatch:
inputs:
release_tag:
description: 'Release Tag'
required: true
type: string
env:
NEW_VERSION: ${{ github.event.inputs.release_tag }}
jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
ref: main
fetch-depth: 0
token: ${{ secrets.PROJECT_TOKEN }}
- name: Modify for next release
run: |
chmod +x release.sh
./release.sh ${{ env.NEW_VERSION }}
yarn
git diff
git config user.name '${{ vars.USER_NAME }}'
git config user.email '${{ vars.USER_EMAIL }}'
git add .
git commit -m 'release: clickstream React Native ${{ env.NEW_VERSION }}'
git push
git tag v${{ env.NEW_VERSION }}
git push origin v${{ env.NEW_VERSION }}
- name: Prepare release file
run: |
yarn
yarn run pack
- name: Create GitHub release
uses: softprops/action-gh-release@v1
with:
name: "Clickstream React Native ${{ env.NEW_VERSION }}"
files: |
*.tgz
tag_name: "v${{ env.NEW_VERSION }}"
prerelease: true
generate_release_notes: true