forked from charliekassel/vuejs-datepicker
-
Notifications
You must be signed in to change notification settings - Fork 0
41 lines (37 loc) · 1.06 KB
/
test.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
name: Test
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build:
runs-on: ubuntu-22.04
if: ${{ github.actor != 'dependabot[bot]' }}
timeout-minutes: 10
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: '20.x'
always-auth: true
registry-url: "https://npm.pkg.github.com"
scope: "@reedsy"
- name: Install
# Skip post-install to avoid malicious scripts stealing PAT
run: npm install --ignore-script
env:
# GITHUB_TOKEN can't access packages hosted in private repos,
# even within the same organisation
NODE_AUTH_TOKEN: ${{ secrets.REEDSY_BOT_PERSONAL_ACCESS_TOKEN }}
- name: Post-install
run: npm rebuild && npm run prepare --if-present
- name: Test
run: npm test
- name: Release
if: ${{ github.ref == 'refs/heads/main' }}
run: ./scripts/release.sh