mirror of
https://github.com/CorentinTh/it-tools.git
synced 2025-04-25 17:26:15 -04:00
ci: added commitlint on pull request
This commit is contained in:
parent
55a1d130a0
commit
5e9c8bd781
1 changed files with 14 additions and 17 deletions
31
.github/workflows/ci.yml
vendored
31
.github/workflows/ci.yml
vendored
|
@ -1,16 +1,16 @@
|
||||||
name: ci
|
name: ci
|
||||||
|
|
||||||
on:
|
on: [pull_request]
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
- master
|
|
||||||
pull_request:
|
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
- master
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
commitlint:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
- uses: wagoid/commitlint-github-action@v2
|
||||||
|
|
||||||
ci:
|
ci:
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
|
|
||||||
|
@ -20,15 +20,15 @@ jobs:
|
||||||
node: [14]
|
node: [14]
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout 🛎
|
- name: Checkout
|
||||||
uses: actions/checkout@master
|
uses: actions/checkout@master
|
||||||
|
|
||||||
- name: Setup node env 🏗
|
- name: Setup node env
|
||||||
uses: actions/setup-node@v2.1.2
|
uses: actions/setup-node@v2.1.2
|
||||||
with:
|
with:
|
||||||
node-version: ${{ matrix.node }}
|
node-version: ${{ matrix.node }}
|
||||||
|
|
||||||
- name: Cache node_modules 📦
|
- name: Cache node_modules
|
||||||
uses: actions/cache@v2
|
uses: actions/cache@v2
|
||||||
with:
|
with:
|
||||||
path: ~/.npm
|
path: ~/.npm
|
||||||
|
@ -36,11 +36,8 @@ jobs:
|
||||||
restore-keys: |
|
restore-keys: |
|
||||||
${{ runner.os }}-node-
|
${{ runner.os }}-node-
|
||||||
|
|
||||||
- name: Install dependencies 👨🏻💻
|
- name: Install dependencies
|
||||||
run: npm ci
|
run: npm ci
|
||||||
|
|
||||||
- name: Run linter 👀
|
- name: Run linter
|
||||||
run: npm run lint
|
run: npm run lint
|
||||||
|
|
||||||
- name: Run tests 🧪
|
|
||||||
run: npm run test
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue