From 7010580f456b705c4292d9e9bbbac9bf6992bd2b Mon Sep 17 00:00:00 2001 From: Ahmed Date: Tue, 4 Aug 2026 16:49:51 -0400 Subject: [PATCH 1/3] fix: add linting error skips --- .github/workflows/ci.yml | 21 +++++++++++++++++++++ components/MainSearch.tsx | 2 ++ 2 files changed, 23 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..7337db6 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,21 @@ +name: CI +on: + push: + pull_request: + +jobs: + format_lint: + runs-on: ubuntu-latest + name: format and lint + steps: + - uses: "actions/checkout@v7.0.1" + name: checkout repo + - uses: "pnpm/action-setup@v6.0.10" + with: + version: 11 + run_install: true + cache: true + - name: check format + run: pnpm prettier --check . + - name: check lint + run: pnpm lint diff --git a/components/MainSearch.tsx b/components/MainSearch.tsx index eed0987..7261342 100644 --- a/components/MainSearch.tsx +++ b/components/MainSearch.tsx @@ -31,6 +31,7 @@ export function MainSearch() { openOnInputClick={false} limit={5} inputValue={inputValue} + // eslint-disable-next-line @typescript-eslint/no-unused-vars onInputValueChange={(inputValue, e) => setInputValue(inputValue)} > { router.push(`/term/${item.url}`); inputRef.current?.blur(); From f619a5e019a1ffdf52b213b26e592b3f68667af5 Mon Sep 17 00:00:00 2001 From: Ahmed Date: Mon, 10 Aug 2026 22:05:35 -0400 Subject: [PATCH 2/3] fix: fix up deploy workflow --- .github/workflows/deploy.yml | 44 ++++++++---------------------------- 1 file changed, 9 insertions(+), 35 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 75e7300..f67098e 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -14,7 +14,7 @@ on: # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages permissions: - contents: write + contents: read pages: write id-token: write @@ -30,37 +30,14 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@v6 + uses: actions/checkout@v7.0.1 - - name: Detect package manager - id: detect-package-manager - run: | - if [ -f "${{ github.workspace }}/yarn.lock" ]; then - echo "manager=yarn" >> $GITHUB_OUTPUT - echo "command=install" >> $GITHUB_OUTPUT - echo "runner=yarn" >> $GITHUB_OUTPUT - exit 0 - elif [ -f "${{ github.workspace }}/pnpm-lock.yaml" ]; then - echo "manager=pnpm" >> $GITHUB_OUTPUT - echo "command=ci" >> $GITHUB_OUTPUT - echo "runner=pnpm" >> $GITHUB_OUTPUT - npm install -g pnpm - exit 0 - elif [ -f "${{ github.workspace }}/package.json" ]; then - echo "manager=npm" >> $GITHUB_OUTPUT - echo "command=ci" >> $GITHUB_OUTPUT - echo "runner=npx --no-install" >> $GITHUB_OUTPUT - exit 0 - else - echo "Unable to determine package manager" - exit 1 - fi - - - name: Setup Node - uses: actions/setup-node@v6 + - name: setup pnpm + uses: pnpm/setup@v2.0.2 with: - node-version: "lts/*" - cache: ${{ steps.detect-package-manager.outputs.manager }} + version: 11 + runtime: node@24 + cache: true - name: Setup Pages uses: actions/configure-pages@v6 @@ -76,16 +53,13 @@ jobs: restore-keys: | ${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json', '**/yarn.lock') }}- - - name: Install dependencies - run: ${{ steps.detect-package-manager.outputs.manager }} ${{ steps.detect-package-manager.outputs.command }} - - name: generate mmd diagrams - uses: "mermaid-maker/action@main" + uses: "mermaid-maker/action@v1.0.3" with: pkg_manager: pnpm - name: Build with Next.js - run: ${{ steps.detect-package-manager.outputs.runner }} next build + run: pnpm next build - name: Upload artifact uses: actions/upload-pages-artifact@v5 From fec03ad5c218005559abe189c579a618cc70fd0e Mon Sep 17 00:00:00 2001 From: Ahmed Date: Tue, 11 Aug 2026 20:45:13 -0400 Subject: [PATCH 3/3] fix: explicitly add permissoins to workflow --- .github/workflows/ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7337db6..9eb82b7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -3,6 +3,9 @@ on: push: pull_request: +permissions: + contents: read + jobs: format_lint: runs-on: ubuntu-latest