From f3dc7fcf7b9b6936599269c93a192cae02c8a893 Mon Sep 17 00:00:00 2001 From: Maidul Islam Date: Wed, 24 May 2023 10:46:39 -0400 Subject: [PATCH] add timout to pull requests --- .github/workflows/check-be-pull-request.yml | 1 + .github/workflows/check-fe-pull-request.yml | 29 +++++++++------------ 2 files changed, 13 insertions(+), 17 deletions(-) diff --git a/.github/workflows/check-be-pull-request.yml b/.github/workflows/check-be-pull-request.yml index 3cb010e8c..d2c2178fb 100644 --- a/.github/workflows/check-be-pull-request.yml +++ b/.github/workflows/check-be-pull-request.yml @@ -13,6 +13,7 @@ jobs: check-be-pr: name: Check runs-on: ubuntu-latest + timeout-minutes: 15 steps: - name: ☁️ Checkout source diff --git a/.github/workflows/check-fe-pull-request.yml b/.github/workflows/check-fe-pull-request.yml index b91e6f060..75465a014 100644 --- a/.github/workflows/check-fe-pull-request.yml +++ b/.github/workflows/check-fe-pull-request.yml @@ -2,40 +2,35 @@ name: Check Frontend Pull Request on: pull_request: - types: [ opened, synchronize ] + types: [opened, synchronize] paths: - - 'frontend/**' - - '!frontend/README.md' - - '!frontend/.*' - - 'frontend/.eslintrc.js' - + - "frontend/**" + - "!frontend/README.md" + - "!frontend/.*" + - "frontend/.eslintrc.js" jobs: - check-fe-pr: name: Check runs-on: ubuntu-latest + timeout-minutes: 15 steps: - - - name: ☁️ Checkout source + - name: ☁️ Checkout source uses: actions/checkout@v3 - - - name: 🔧 Setup Node 16 + - name: 🔧 Setup Node 16 uses: actions/setup-node@v3 with: - node-version: '16' - cache: 'npm' + node-version: "16" + cache: "npm" cache-dependency-path: frontend/package-lock.json - - - name: 📦 Install dependencies + - name: 📦 Install dependencies run: npm ci --only-production --ignore-scripts working-directory: frontend # - # name: 🧪 Run tests # run: npm run test:ci # working-directory: frontend - - - name: 🏗️ Run build + - name: 🏗️ Run build run: npm run build working-directory: frontend