From 4c83a7021f5dfde43fe2ef4addeda6478937c0be Mon Sep 17 00:00:00 2001 From: Mathias Fredriksson Date: Sat, 7 Mar 2026 01:22:00 +0200 Subject: [PATCH] fix: update offlinedocs/next-env.d.ts to match Next.js 15 output (#22739) ## Problem `offlinedocs/next-env.d.ts` was committed with content from an older Next.js version. Next.js 15 rewrites this file on every `next build` with two changes: 1. Adds `/// ` 2. Updates the docs URL from `basic-features/typescript` to `pages/api-reference/config/typescript` During `make pre-commit` / `make pre-push`, the `pnpm export` step triggers `next build`, which silently rewrites the file. The `check-unstaged` guard then detects the diff and fails. If the hook is interrupted, the regenerated file persists as an unstaged change, blocking subsequent commits/pushes. ## Fix Update the committed file to match what the current Next.js 15 produces, making the build idempotent. --- .github/workflows/ci.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 58203e2123..9bf856c955 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -986,6 +986,9 @@ jobs: run: | make build/coder_docs_"$(./scripts/version.sh)".tgz + - name: Check for unstaged files + run: ./scripts/check_unstaged.sh + required: runs-on: ubuntu-latest needs: