-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (34 loc) · 945 Bytes
/
deploy.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
name: release
on:
push:
branches:
- main
jobs:
deploy:
name: deploy
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: get node version
run: echo "::set-output name=NODE_VERSION::$(node -p "JSON.parse(fs.readFileSync('./.versions','utf8')).node")"
id: node_version
- name: setup node
uses: actions/setup-node@v2
with:
node-version: ${{ steps.node_version.outputs.NODE_VERSION }}
cache: 'npm'
- name: install dependencies
env:
HUSKY: 0
run: npm install
- name: run semantic-release
run: npx semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: deploy to cloudflare workers
uses: cloudflare/[email protected]
with:
apiToken: ${{ secrets.CF_API_TOKEN }}