-
Notifications
You must be signed in to change notification settings - Fork 1
34 lines (28 loc) · 990 Bytes
/
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
name: CI
on: push
jobs:
build-and-test:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: "16" # Spécifiez la version de Node.js que vous utilisez
- name: Install Dependencies
run: npm install
- name: Run Linter
run: npm run lint
- name: Run Unit Tests
run: npm run test
- name: Create Pull Request
if: github.event_name == 'push' && github.ref == 'refs/heads/feature/**'
uses: peter-evans/create-pull-request@v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
commit-message: "Automated PR - ${{ github.event.head_commit.message }}"
title: "Automated PR: ${{ github.event.head_commit.message }}"
body: "${{ github.event.head_commit.message }}"
branch: "ci-autopr-${{ github.run_id }}"
base: main