-
Notifications
You must be signed in to change notification settings - Fork 6
53 lines (44 loc) · 1.26 KB
/
create-version.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
name: Create New Version
run-name: Creating new ${{ github.event.inputs.version }} ${{ github.event.inputs.channel }} version
on:
workflow_dispatch:
inputs:
version:
description: Version
type: choice
options:
- major
- minor
- patch
default: minor
channel:
description: Channel
type: choice
options:
- release
- beta
default: release
env:
CI: true
permissions:
contents: write
jobs:
version:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
token: ${{ secrets.BCC_BOT_ACCESS_TOKEN }}
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
registry-url: 'https://registry.npmjs.org'
- name: Set commit author to bcc-bot
run: |
git config --global user.name "bcc-bot"
git config --global user.email "[email protected]"
- name: Version new ${{ github.event.inputs.version }} version
run: npm run create-version -- ${{ github.event.inputs.version }} ${{ github.event.inputs.channel }}
- name: Push
run: git push --follow-tags --force