-
Notifications
You must be signed in to change notification settings - Fork 0
44 lines (44 loc) · 1.08 KB
/
node-ci.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
name: Node.js CI
'on':
push:
branches:
- master
- beta
- renovate/**
pull_request:
types:
- opened
- synchronize
env:
FORCE_COLOR: 1
NPM_CONFIG_COLOR: always
jobs:
verify:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3
- name: Setup node
uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3
with:
node-version-file: .nvmrc
cache: npm
- run: npm clean-install
- run: npm test
- uses: codecov/codecov-action@eaaf4bedf32dbdc6b720b63067d99c4d77d6047d # v3
trigger-release:
runs-on: ubuntu-latest
if: github.event_name == 'push'
needs:
- verify
steps:
- uses: octokit/request-action@v2.x
with:
route: >-
POST
/repos/{owner}/{repo}/actions/workflows/{workflow_id}/dispatches
owner: form8ion
repo: gatsby
ref: ${{ github.ref }}
workflow_id: release.yml
env:
GITHUB_TOKEN: ${{ secrets.GH_PAT }}