From 72987adc2f8cbdd7b85edbc24d5f53efa3ceacc8 Mon Sep 17 00:00:00 2001 From: Viachaslau Tyshkavets Date: Mon, 2 Sep 2024 12:41:36 +0400 Subject: [PATCH] chore(client): setup gh ci checks for client app --- .github/workflows/check-client.yml | 49 ++++++++++++++++++++++++++++++ .github/workflows/check.yml | 10 +++--- 2 files changed, 55 insertions(+), 4 deletions(-) create mode 100644 .github/workflows/check-client.yml diff --git a/.github/workflows/check-client.yml b/.github/workflows/check-client.yml new file mode 100644 index 00000000..c2e9d87c --- /dev/null +++ b/.github/workflows/check-client.yml @@ -0,0 +1,49 @@ +name: "React Front-End CI checks" + +on: + pull_request: + branches: + - '**' + + push: + branches: + - stable + - unstable + + paths: + - 'client/**' + - '.github/workflows/*client.yml' + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + check: + runs-on: ubuntu-latest + strategy: + matrix: + node-version: [18.x] + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Setup Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - name: Install dependencies + run: npm ci --prefix=client --no-audit + + - name: Check format + run: npm run format --prefix=client + + - name: Lint + run: npm run lint --prefix=client + + - name: Build + run: npm run build --prefix=client + + - name: Test + run: npm run test --prefix=client diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index bf2d4426..b730d51b 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -1,18 +1,20 @@ -name: "Nest Back-End format, lint and build checks" +name: "Nest Back-End CI checks" on: pull_request: branches: - '**' - + push: branches: - stable - unstable - + paths: + - '*' - 'src/**' - 'test/**' + - '.github/workflows/check.yml' concurrency: group: ${{ github.workflow }}-${{ github.ref }} @@ -34,7 +36,7 @@ jobs: node-version: ${{ matrix.node-version }} - name: Install dependencies - run: npm ci + run: npm ci --no-audit - name: Check format run: npm run format