From 921e162b1fa2c85de329642dec741ce0278d2b9a Mon Sep 17 00:00:00 2001 From: pure-js <3690368+pure-js@users.noreply.github.com> Date: Sat, 9 Sep 2023 13:00:10 +0400 Subject: [PATCH] ci: fix deploy pipeline --- .github/workflows/deploy-to-gh-pages.yml | 18 +++++++++++++----- .github/workflows/lighthouse.yml | 1 + .github/workflows/lint.yml | 6 ++++-- .github/workflows/playwright.yml | 4 +++- .github/workflows/release-please.yml | 4 +++- .github/workflows/test.yml | 6 ++++-- 6 files changed, 28 insertions(+), 11 deletions(-) diff --git a/.github/workflows/deploy-to-gh-pages.yml b/.github/workflows/deploy-to-gh-pages.yml index f3897b94..ac17052d 100644 --- a/.github/workflows/deploy-to-gh-pages.yml +++ b/.github/workflows/deploy-to-gh-pages.yml @@ -1,4 +1,5 @@ name: Deploy Release Build to GitHub pages + on: push: branches: @@ -12,14 +13,21 @@ env: jobs: publish: runs-on: ubuntu-latest + strategy: + matrix: + node-version: [18] steps: - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 + - uses: pnpm/action-setup@v2 + with: + version: 8 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 with: - node-version: '18' - cache: 'npm' - - name: Install modules - run: npm ci + node-version: ${{ matrix.node-version }} + cache: 'pnpm' + - name: Install dependencies + run: pnpm install - name: Deploy with gh-pages run: | git remote set-url origin https://git:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git diff --git a/.github/workflows/lighthouse.yml b/.github/workflows/lighthouse.yml index 8f8c5c9a..f96f7014 100644 --- a/.github/workflows/lighthouse.yml +++ b/.github/workflows/lighthouse.yml @@ -1,4 +1,5 @@ name: Lighthouse CI + on: [push] env: diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index aced5b02..36026546 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -1,5 +1,7 @@ name: Code Linting + on: push + jobs: eslint: runs-on: ubuntu-latest @@ -16,7 +18,7 @@ jobs: with: node-version: ${{ matrix.node-version }} cache: 'pnpm' - - name: Install modules - run: pnpm i + - name: Install dependencies + run: pnpm install - name: Run ESLint run: pnpm run lint diff --git a/.github/workflows/playwright.yml b/.github/workflows/playwright.yml index b94e4213..9d5065b1 100644 --- a/.github/workflows/playwright.yml +++ b/.github/workflows/playwright.yml @@ -1,9 +1,11 @@ name: Playwright End-to-End Tests + on: push: branches: [main] pull_request: branches: [main] + jobs: playwright: timeout-minutes: 60 @@ -25,7 +27,7 @@ jobs: node-version: ${{ matrix.node-version }} cache: 'pnpm' - name: Install dependencies - run: pnpm i + run: pnpm install - name: Install Playwright Browsers run: npx playwright install --with-deps - name: Run Playwright tests diff --git a/.github/workflows/release-please.yml b/.github/workflows/release-please.yml index 190264ff..e8a215ee 100644 --- a/.github/workflows/release-please.yml +++ b/.github/workflows/release-please.yml @@ -1,8 +1,10 @@ +name: Release Please + on: push: branches: - main -name: release-please + jobs: release-please: runs-on: ubuntu-latest diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 2cfd5397..0be43123 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,5 +1,7 @@ name: Unit Testing + on: push + jobs: jest: runs-on: ubuntu-latest @@ -16,7 +18,7 @@ jobs: with: node-version: ${{ matrix.node-version }} cache: 'pnpm' - - name: Install modules - run: pnpm i + - name: Install dependencies + run: pnpm install - name: Run tests run: pnpm test