-
Notifications
You must be signed in to change notification settings - Fork 2
51 lines (43 loc) · 1.08 KB
/
main.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
name: Pull-Request-CI
on:
pull_request:
branches:
- main
paths:
- "lib/**"
- "tests/**"
tags-ignore:
- "**"
env:
BRANCH_NAME: ${{ github.head_ref || github.ref_name }}
jobs:
build_and_test:
runs-on: ubuntu-latest
strategy:
max-parallel: 1
matrix:
node-version: [14]
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: run npm install
run: npm install
- name: check lint
run: npm run lint
- name: run tests
run: npm test
gitleaks:
runs-on: ubuntu-20.04
steps:
- name: Add Homebrew to $PATH
run: echo "/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin" >> $GITHUB_PATH
- uses: actions/checkout@v3
- name: Install GitLeaks
run: |
brew install gitleaks
- name: gitleaks-action
run: |
gitleaks --verbose detect --log-opts --since="2021-11-25"