From 6af8d043a599ab5d740033f22375cac7d6db0b37 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 15 Jan 2026 11:37:08 +0000 Subject: [PATCH 1/9] Initial plan From 22aaffbb79d439685524a405f77eaf9dca128a1d Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 15 Jan 2026 11:41:36 +0000 Subject: [PATCH 2/9] Add automation workflows for CI, dependencies, and PR management Co-authored-by: huangyiirene <7665279+huangyiirene@users.noreply.github.com> --- .github/dependabot.yml | 30 +++++++++++++++++ .github/labeler.yml | 38 ++++++++++++++++++++++ .github/markdown-link-check-config.json | 17 ++++++++++ .github/workflows/ci.yml | 43 +++++++++++++++++++++++++ .github/workflows/label.yml | 23 +++++++++++++ .github/workflows/link-check.yml | 31 ++++++++++++++++++ .github/workflows/preview.yml | 43 +++++++++++++++++++++++++ 7 files changed, 225 insertions(+) create mode 100644 .github/dependabot.yml create mode 100644 .github/labeler.yml create mode 100644 .github/markdown-link-check-config.json create mode 100644 .github/workflows/ci.yml create mode 100644 .github/workflows/label.yml create mode 100644 .github/workflows/link-check.yml create mode 100644 .github/workflows/preview.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..4a6e8c3 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,30 @@ +version: 2 +updates: + # Enable version updates for npm + - package-ecosystem: "npm" + directory: "/" + schedule: + interval: "weekly" + day: "monday" + open-pull-requests-limit: 10 + labels: + - "dependencies" + - "automated" + commit-message: + prefix: "chore" + prefix-development: "chore" + include: "scope" + reviewers: + - "objectstack-ai/maintainers" + + # Enable version updates for GitHub Actions + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "monthly" + labels: + - "dependencies" + - "github-actions" + commit-message: + prefix: "ci" + include: "scope" diff --git a/.github/labeler.yml b/.github/labeler.yml new file mode 100644 index 0000000..c0ea53a --- /dev/null +++ b/.github/labeler.yml @@ -0,0 +1,38 @@ +documentation: + - changed-files: + - any-glob-to-any-file: + - 'content/**/*.mdx' + - '*.md' + +i18n: + - changed-files: + - any-glob-to-any-file: + - 'content/**/*.zh-CN.mdx' + - 'content/**/*.en.mdx' + - 'lib/i18n.ts' + +ui: + - changed-files: + - any-glob-to-any-file: + - 'app/**/*.tsx' + - 'app/**/*.ts' + - '*.tsx' + +configuration: + - changed-files: + - any-glob-to-any-file: + - '*.config.*' + - '*.json' + - 'tsconfig.json' + +dependencies: + - changed-files: + - any-glob-to-any-file: + - 'package.json' + - 'package-lock.json' + - 'pnpm-lock.yaml' + +workflows: + - changed-files: + - any-glob-to-any-file: + - '.github/**' diff --git a/.github/markdown-link-check-config.json b/.github/markdown-link-check-config.json new file mode 100644 index 0000000..a5056b3 --- /dev/null +++ b/.github/markdown-link-check-config.json @@ -0,0 +1,17 @@ +{ + "ignorePatterns": [ + { + "pattern": "^http://localhost" + }, + { + "pattern": "^https://localhost" + } + ], + "replacements": [], + "httpHeaders": [], + "timeout": "20s", + "retryOn429": true, + "retryCount": 3, + "fallbackRetryDelay": "30s", + "aliveStatusCodes": [200, 206, 301, 302, 307, 308] +} diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..abe8c50 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,43 @@ +name: CI + +on: + pull_request: + branches: + - main + push: + branches: + - main + +jobs: + build: + name: Build and Test + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version: '20' + cache: 'npm' + + - name: Install dependencies + run: npm ci + + - name: Type check + run: npx tsc --noEmit + + - name: Build + run: npm run build + env: + NODE_ENV: production + + - name: Upload build artifacts + uses: actions/upload-artifact@v4 + if: success() + with: + name: build-output + path: .next + retention-days: 7 diff --git a/.github/workflows/label.yml b/.github/workflows/label.yml new file mode 100644 index 0000000..6634630 --- /dev/null +++ b/.github/workflows/label.yml @@ -0,0 +1,23 @@ +name: PR Labeler + +on: + pull_request: + types: [opened, synchronize, reopened] + +jobs: + label: + name: Auto Label PR + runs-on: ubuntu-latest + permissions: + contents: read + pull-requests: write + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Label based on changed files + uses: actions/labeler@v5 + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} + configuration-path: .github/labeler.yml diff --git a/.github/workflows/link-check.yml b/.github/workflows/link-check.yml new file mode 100644 index 0000000..b200b53 --- /dev/null +++ b/.github/workflows/link-check.yml @@ -0,0 +1,31 @@ +name: Link Check + +on: + pull_request: + paths: + - 'content/**' + - '**.md' + - '**.mdx' + schedule: + # Run weekly on Monday at 00:00 UTC + - cron: '0 0 * * 1' + workflow_dispatch: + +jobs: + link-check: + name: Check Links + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Check links in markdown files + uses: gaurav-nelson/github-action-markdown-link-check@v1 + with: + use-quiet-mode: 'yes' + use-verbose-mode: 'no' + config-file: '.github/markdown-link-check-config.json' + folder-path: 'content/' + file-extension: '.mdx' + check-modified-files-only: 'yes' diff --git a/.github/workflows/preview.yml b/.github/workflows/preview.yml new file mode 100644 index 0000000..af165a5 --- /dev/null +++ b/.github/workflows/preview.yml @@ -0,0 +1,43 @@ +name: Preview Deployment + +on: + pull_request: + types: [opened, synchronize, reopened] + +jobs: + preview-info: + name: Preview Information + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Comment PR with deployment info + uses: actions/github-script@v7 + with: + script: | + const prNumber = context.issue.number; + const repoName = context.repo.repo; + const ownerName = context.repo.owner; + + const comment = `## 🚀 Preview Deployment + + This pull request will be automatically deployed to Vercel when merged. + + ### Preview Links + - 📝 **Documentation**: Will be available once Vercel deployment completes + - 🌍 **Languages**: English (\`/en/docs\`) and Chinese (\`/zh-CN/docs\`) + + ### Build Status + Check the CI workflow for build status and any errors. + + --- + *Automated preview information for PR #${prNumber}*`; + + github.rest.issues.createComment({ + issue_number: context.issue.number, + owner: context.repo.owner, + repo: context.repo.repo, + body: comment + }); From 7e59104e7e1c54c43de3d2d0afc95c78b34c24ee Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 15 Jan 2026 11:43:32 +0000 Subject: [PATCH 3/9] Address code review feedback: improve link checking and remove team reviewers Co-authored-by: huangyiirene <7665279+huangyiirene@users.noreply.github.com> --- .github/dependabot.yml | 2 -- .github/workflows/link-check.yml | 11 ++++++++++- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 4a6e8c3..954ff62 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -14,8 +14,6 @@ updates: prefix: "chore" prefix-development: "chore" include: "scope" - reviewers: - - "objectstack-ai/maintainers" # Enable version updates for GitHub Actions - package-ecosystem: "github-actions" diff --git a/.github/workflows/link-check.yml b/.github/workflows/link-check.yml index b200b53..f4d2dfb 100644 --- a/.github/workflows/link-check.yml +++ b/.github/workflows/link-check.yml @@ -20,7 +20,7 @@ jobs: - name: Checkout code uses: actions/checkout@v4 - - name: Check links in markdown files + - name: Check links in MDX files uses: gaurav-nelson/github-action-markdown-link-check@v1 with: use-quiet-mode: 'yes' @@ -29,3 +29,12 @@ jobs: folder-path: 'content/' file-extension: '.mdx' check-modified-files-only: 'yes' + + - name: Check links in markdown files + uses: gaurav-nelson/github-action-markdown-link-check@v1 + with: + use-quiet-mode: 'yes' + use-verbose-mode: 'no' + config-file: '.github/markdown-link-check-config.json' + file-extension: '.md' + check-modified-files-only: 'yes' From 5d2acaca89217684e0ecd9dd0bc8c24edceddf11 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 15 Jan 2026 11:45:03 +0000 Subject: [PATCH 4/9] Fix link checking for scheduled runs, remove unused variables, and refine labeler patterns Co-authored-by: huangyiirene <7665279+huangyiirene@users.noreply.github.com> --- .github/labeler.yml | 2 +- .github/workflows/link-check.yml | 4 ++-- .github/workflows/preview.yml | 2 -- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/.github/labeler.yml b/.github/labeler.yml index c0ea53a..d2bb740 100644 --- a/.github/labeler.yml +++ b/.github/labeler.yml @@ -22,8 +22,8 @@ configuration: - changed-files: - any-glob-to-any-file: - '*.config.*' - - '*.json' - 'tsconfig.json' + - 'vercel.json' dependencies: - changed-files: diff --git a/.github/workflows/link-check.yml b/.github/workflows/link-check.yml index f4d2dfb..f7119bf 100644 --- a/.github/workflows/link-check.yml +++ b/.github/workflows/link-check.yml @@ -28,7 +28,7 @@ jobs: config-file: '.github/markdown-link-check-config.json' folder-path: 'content/' file-extension: '.mdx' - check-modified-files-only: 'yes' + check-modified-files-only: ${{ github.event_name == 'pull_request' && 'yes' || 'no' }} - name: Check links in markdown files uses: gaurav-nelson/github-action-markdown-link-check@v1 @@ -37,4 +37,4 @@ jobs: use-verbose-mode: 'no' config-file: '.github/markdown-link-check-config.json' file-extension: '.md' - check-modified-files-only: 'yes' + check-modified-files-only: ${{ github.event_name == 'pull_request' && 'yes' || 'no' }} diff --git a/.github/workflows/preview.yml b/.github/workflows/preview.yml index af165a5..f29d71b 100644 --- a/.github/workflows/preview.yml +++ b/.github/workflows/preview.yml @@ -18,8 +18,6 @@ jobs: with: script: | const prNumber = context.issue.number; - const repoName = context.repo.repo; - const ownerName = context.repo.owner; const comment = `## 🚀 Preview Deployment From 93eea7ab1b2c9095d1bd7d6b5d3f1d619c5c65e3 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 15 Jan 2026 11:46:25 +0000 Subject: [PATCH 5/9] Fix link checker configuration to properly handle folder and file paths Co-authored-by: huangyiirene <7665279+huangyiirene@users.noreply.github.com> --- .github/workflows/link-check.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/link-check.yml b/.github/workflows/link-check.yml index f7119bf..223b68a 100644 --- a/.github/workflows/link-check.yml +++ b/.github/workflows/link-check.yml @@ -20,21 +20,20 @@ jobs: - name: Checkout code uses: actions/checkout@v4 - - name: Check links in MDX files + - name: Check links in content directory uses: gaurav-nelson/github-action-markdown-link-check@v1 with: use-quiet-mode: 'yes' use-verbose-mode: 'no' config-file: '.github/markdown-link-check-config.json' folder-path: 'content/' - file-extension: '.mdx' check-modified-files-only: ${{ github.event_name == 'pull_request' && 'yes' || 'no' }} - - name: Check links in markdown files + - name: Check links in root markdown files uses: gaurav-nelson/github-action-markdown-link-check@v1 with: use-quiet-mode: 'yes' use-verbose-mode: 'no' config-file: '.github/markdown-link-check-config.json' - file-extension: '.md' + file-path: './README.md' check-modified-files-only: ${{ github.event_name == 'pull_request' && 'yes' || 'no' }} From c776949cc6cfbd5c1e3498ac68a8d900c72fcae0 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 15 Jan 2026 11:47:39 +0000 Subject: [PATCH 6/9] Add explicit GITHUB_TOKEN permissions to workflows for security Co-authored-by: huangyiirene <7665279+huangyiirene@users.noreply.github.com> --- .github/workflows/ci.yml | 2 ++ .github/workflows/link-check.yml | 2 ++ .github/workflows/preview.yml | 3 +++ 3 files changed, 7 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index abe8c50..fcdd58b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -12,6 +12,8 @@ jobs: build: name: Build and Test runs-on: ubuntu-latest + permissions: + contents: read steps: - name: Checkout code diff --git a/.github/workflows/link-check.yml b/.github/workflows/link-check.yml index 223b68a..58cc64b 100644 --- a/.github/workflows/link-check.yml +++ b/.github/workflows/link-check.yml @@ -15,6 +15,8 @@ jobs: link-check: name: Check Links runs-on: ubuntu-latest + permissions: + contents: read steps: - name: Checkout code diff --git a/.github/workflows/preview.yml b/.github/workflows/preview.yml index f29d71b..931524a 100644 --- a/.github/workflows/preview.yml +++ b/.github/workflows/preview.yml @@ -8,6 +8,9 @@ jobs: preview-info: name: Preview Information runs-on: ubuntu-latest + permissions: + contents: read + pull-requests: write steps: - name: Checkout code From f1342309ab9be1a0aaf0dccd36f88435f5942212 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 15 Jan 2026 11:49:15 +0000 Subject: [PATCH 7/9] Pin action versions to specific releases and fix deployment comment Co-authored-by: huangyiirene <7665279+huangyiirene@users.noreply.github.com> --- .github/workflows/label.yml | 2 +- .github/workflows/link-check.yml | 4 ++-- .github/workflows/preview.yml | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/label.yml b/.github/workflows/label.yml index 6634630..acc7de0 100644 --- a/.github/workflows/label.yml +++ b/.github/workflows/label.yml @@ -17,7 +17,7 @@ jobs: uses: actions/checkout@v4 - name: Label based on changed files - uses: actions/labeler@v5 + uses: actions/labeler@v5.0.0 with: repo-token: ${{ secrets.GITHUB_TOKEN }} configuration-path: .github/labeler.yml diff --git a/.github/workflows/link-check.yml b/.github/workflows/link-check.yml index 58cc64b..e7084ee 100644 --- a/.github/workflows/link-check.yml +++ b/.github/workflows/link-check.yml @@ -23,7 +23,7 @@ jobs: uses: actions/checkout@v4 - name: Check links in content directory - uses: gaurav-nelson/github-action-markdown-link-check@v1 + uses: gaurav-nelson/github-action-markdown-link-check@v1.0.15 with: use-quiet-mode: 'yes' use-verbose-mode: 'no' @@ -32,7 +32,7 @@ jobs: check-modified-files-only: ${{ github.event_name == 'pull_request' && 'yes' || 'no' }} - name: Check links in root markdown files - uses: gaurav-nelson/github-action-markdown-link-check@v1 + uses: gaurav-nelson/github-action-markdown-link-check@v1.0.15 with: use-quiet-mode: 'yes' use-verbose-mode: 'no' diff --git a/.github/workflows/preview.yml b/.github/workflows/preview.yml index 931524a..eba71f9 100644 --- a/.github/workflows/preview.yml +++ b/.github/workflows/preview.yml @@ -24,7 +24,7 @@ jobs: const comment = `## 🚀 Preview Deployment - This pull request will be automatically deployed to Vercel when merged. + This pull request will be automatically deployed to Vercel. ### Preview Links - 📝 **Documentation**: Will be available once Vercel deployment completes From 907ec827a199784196e1465481d40f4dc58d75d5 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 15 Jan 2026 12:33:08 +0000 Subject: [PATCH 8/9] Initial plan From 0a4d9f3568832937bbe5512a1aff2e11c0e7a427 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 15 Jan 2026 12:45:04 +0000 Subject: [PATCH 9/9] Add source file generation step before type checking in CI Co-authored-by: huangyiirene <7665279+huangyiirene@users.noreply.github.com> --- .github/workflows/ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index fcdd58b..4548ec4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -28,6 +28,9 @@ jobs: - name: Install dependencies run: npm ci + - name: Generate source files + run: npx fumadocs-mdx + - name: Type check run: npx tsc --noEmit