diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b70f5276..e2ee7d35 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -20,6 +20,8 @@ jobs: lint: runs-on: ubuntu-latest + timeout-minutes: 15 + steps: - name: Update apt run: sudo apt-get update || exit 0 @@ -58,6 +60,8 @@ jobs: prettier: runs-on: ubuntu-latest + timeout-minutes: 15 + steps: - name: Update apt run: sudo apt-get update || exit 0 @@ -96,9 +100,27 @@ jobs: - run: npm run prettier:check + depcheck: + runs-on: ubuntu-latest + + timeout-minutes: 15 + + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Setup project + uses: ./.github/actions/setup-project + with: + CACHE_VERSION: ${{ secrets.CACHE_VERSION }} + + - run: npm run depcheck + test: runs-on: ubuntu-latest + timeout-minutes: 30 + services: redis: image: redis diff --git a/package.json b/package.json index ba1f6d21..5714f485 100644 --- a/package.json +++ b/package.json @@ -54,7 +54,8 @@ "prettier:write": "npm run prettier -- --write", "start": "node dist/server", "test:server": "TZ=UTC ./scripts/run_test.sh", - "prepare": "husky install" + "prepare": "husky install", + "depcheck": "npx depcheck" }, "devDependencies": { "@babel/cli": "^7.23.4", @@ -98,5 +99,10 @@ "cacheDirectories": [ "node_modules" ], + "depcheck": { + "ignores": [ + "jest" + ] + }, "heroku-run-build-script": true }