-
Notifications
You must be signed in to change notification settings - Fork 1
56 lines (56 loc) · 2.04 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
46
47
48
49
50
51
52
53
54
55
56
name: Bump PR & NPM Dev Publish
on:
pull_request:
types: [closed]
branches: release
jobs:
bump-pr:
runs-on: ubuntu-latest
if: startsWith(github.head_ref, 'release-please-') == false && github.event.pull_request.merged == true
steps:
- uses: google-github-actions/release-please-action@v3
id: ga
with:
release-type: node
changelog-types: '[{"type":"feat","section":"Features"},{"type":"fix","section":"Bug Fixes"},{"type":"perf","section":"Performance Improvements"},{"type":"test","section":"Tests"},{"type":"docs","section":"Documentation"},{"type":"build","section":"Build System"},{"type":"ops","section":"CI/CD Changes"},{"type":"chore","section":"Miscellaneous Chores"},{"type":"refactor","section":"Refactored"}]'
default-branch: release
npm-dev-publish:
runs-on: ubuntu-latest
if: startsWith(github.head_ref, 'release-please-') == false && github.event.pull_request.merged == true
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Make prerelease to npm
uses: epeli/npm-release@v1
with:
type: prerelease
token: ${{ secrets.NPM_AUTOMATION_TOKEN_DTSSTN_LOCAL }}
- name: Extract prerelease version
run: echo "NPM_RELEASE_VERSION=$(echo $NPM_RELEASE_VERSION | cut -c 1-6)" >> $GITHUB_ENV
build-storybook:
runs-on: ubuntu-latest
needs: npm-dev-publish
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Node
uses: actions/setup-node@v3
with:
node-version: 16
registry-url: 'https://registry.npmjs.org'
- name: Install
run: npm ci
- name: Build Storybook
run: npm run build-storybook
- name: Deploy
uses: JamesIves/github-pages-deploy-action@v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
target-folder: release
branch: gh-pages
folder: storybook-static
clean: true