fix: settings page active sidebar item #2371
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI - Client | |
on: | |
push: | |
paths: | |
- 'client/**' | |
- 'api/src/@shared/**' | |
- 'package.json' | |
- '.github/workflows/main-client.yml' | |
env: | |
NODE_VERSION: '20' | |
PNPM_VERSION: 8 | |
jobs: | |
cache-modules: | |
name: Cache Node Modules | |
runs-on: ubuntu-latest | |
outputs: | |
should_skip: ${{ steps.skip_check.outputs.should_skip }} | |
steps: | |
- name: Check for dupe action | |
id: skip_check | |
uses: fkirc/skip-duplicate-actions@v5 | |
continue-on-error: true | |
- uses: actions/checkout@v3 | |
if: steps.skip_check.outputs.should_skip != 'true' | |
- name: Install pnpm | |
if: steps.skip_check.outputs.should_skip != 'true' | |
uses: pnpm/action-setup@v2 | |
with: | |
version: ${{ env.PNPM_VERSION }} | |
- uses: actions/setup-node@v3 | |
if: steps.skip_check.outputs.should_skip != 'true' | |
id: setup-node | |
with: | |
cache: 'pnpm' | |
node-version: ${{ env.NODE_VERSION }} | |
- name: Install packages | |
if: steps.skip_check.outputs.should_skip != 'true' && steps.setup-node.outputs.cache-hit != 'true' | |
run: pnpm install --frozen-lockfile --ignore-scripts | |
lint: | |
name: Lint | |
runs-on: ubuntu-latest | |
needs: [cache-modules] | |
if: needs.cache-modules.outputs.should_skip != 'true' && contains(fromJson('["ved-bot", "renovate[bot]"]'), github.actor) == false | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install pnpm | |
uses: pnpm/action-setup@v2 | |
with: | |
version: ${{ env.PNPM_VERSION }} | |
- uses: actions/setup-node@v3 | |
with: | |
cache: 'pnpm' | |
node-version: ${{ env.NODE_VERSION }} | |
- name: Install packages | |
run: pnpm install | |
- name: Lint | |
run: pnpm run --filter ./client lint | |
build: | |
name: Build | |
runs-on: ubuntu-latest | |
needs: [cache-modules] | |
if: needs.cache-modules.outputs.should_skip != 'true' | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install pnpm | |
uses: pnpm/action-setup@v2 | |
with: | |
version: ${{ env.PNPM_VERSION }} | |
- uses: actions/setup-node@v3 | |
with: | |
cache: 'pnpm' | |
node-version: ${{ env.NODE_VERSION }} | |
- name: Install packages | |
run: pnpm install | |
- name: Init | |
run: pnpm run init --no-db-push | |
- name: Build | |
run: pnpm run --filter ./client build | |
- name: Cache Build Folders | |
if: contains(fromJson('["ved-bot"]'), github.actor) == false | |
uses: actions/cache/save@v3 | |
with: | |
path: | | |
client/.vercel | |
client/.svelte-kit | |
api/src/_generated | |
key: client~build-${{ env.NODE_VERSION }}-${{ runner.os }}-${{ hashFiles('client/package.json', 'client/.vercel/**', 'client/.svelte-kit/**', 'api/src/_generated/**') }} | |
validate: | |
name: Validate | |
runs-on: ubuntu-latest | |
needs: [cache-modules, build] | |
if: needs.cache-modules.outputs.should_skip != 'true' && contains(fromJson('["ved-bot"]'), github.actor) == false | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install pnpm | |
uses: pnpm/action-setup@v2 | |
with: | |
version: ${{ env.PNPM_VERSION }} | |
- uses: actions/setup-node@v3 | |
with: | |
cache: 'pnpm' | |
node-version: ${{ env.NODE_VERSION }} | |
- name: Install packages | |
run: pnpm install | |
- name: Fetch Cached Build Folders | |
uses: actions/cache/restore@v3 | |
with: | |
path: | | |
client/.vercel | |
client/.svelte-kit | |
api/src/_generated | |
key: client~build-${{ env.NODE_VERSION }}-${{ runner.os }}-${{ hashFiles('client/package.json', 'client/.vercel/**', 'client/.svelte-kit/**', 'api/src/_generated/**') }} | |
restore-keys: | | |
client~build-${{ env.NODE_VERSION }}-${{ runner.os }}- | |
- name: Validate | |
run: pnpm run --filter ./client validate |