-
Notifications
You must be signed in to change notification settings - Fork 5
95 lines (75 loc) · 2.32 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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
name: RELEASE
on:
push:
branches:
- master
# paths-ignore:
# - 'www/**'
concurrency:
group: ${{ github.workflow }}
cancel-in-progress: true
jobs:
release:
if: ${{ contains(github.event.head_commit.message, 'release version') }}
runs-on: ubuntu-latest
env:
NEXT_PUBLIC_BASE_URL: https://infinite-table.com/.netlify/functions/json-server
strategy:
matrix:
node-version: [16.x]
steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- uses: './.github/actions/will-release-check'
env:
NPM_REGISTRY_TOKEN: ${{ secrets.NPM_REGISTRY_TOKEN }}
- name: Echo whoami on public npm registry
run: npm whoami
- name: Echo publish cmd
run: echo $WILL_RELEASE_CMD
- name: Set git config
run: |
git config --local user.email "[email protected]"
git config --local user.name "SHIP IT"
- name: Install
run: npm ci
- name: Build test app
run: npm run ci:test:build
- name: Running Playwright Tests
run: npm run ci:test:run
# - name: Linting
# run: npm run lint
# working-directory: source
- name: Update TOC in markdown files
run: npm run doctoc
- name: Bump version
working-directory: source
run: npm run bump:${WILL_RELEASE_VERSION}
- name: Building
run: npm run build
- name: copy .npmrc
run: cp .npmrc source && cp .npmrc source/dist
- name: Ship it
uses: './.github/actions/execute-cmd'
with:
cmd_to_execute: $WILL_RELEASE_CMD
- run: git diff
- run: cat package.json
working-directory: source
- name: Push changes
uses: './.github/actions/git-push-action'
with:
branch: master
github_token: ${{ secrets.DEPLOY_GITHUB_TOKEN }}
# - name: Send version to slack
# uses: "./.github/actions/send-version-to-slack"
# with:
# slack_webhook_notify: ${{ secrets.SLACK_WEBHOOK_NOTIFY }}
publish-docs-on-release:
needs: release
name: 'Rebuilds website'
uses: ./.github/workflows/rebuild-website.yml
secrets: inherit