-
Notifications
You must be signed in to change notification settings - Fork 4
45 lines (37 loc) · 1016 Bytes
/
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
on:
workflow_dispatch:
inputs:
increment:
type: choice
options:
- patch
- minor
- major
jobs:
release:
name: Release
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup node
id: setup-node
uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
- name: git config
run: |
git config user.name "${GITHUB_ACTOR}"
git config user.email "${GITHUB_ACTOR}@users.noreply.github.com"
- name: npm config
run: |
npm config set --global //registry.npmjs.org/:_authToken ${{ secrets.NPM_TOKEN }}
- name: Install dependencies
run: yarn --frozen-lockfile
- name: Release
run: yarn release-it ${{ inputs.increment }}
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}