From 445d9e15e3df0a39bf2fb9050f22b55899728570 Mon Sep 17 00:00:00 2001 From: Alex-Zughaid <117576511+Alex-Zughaid@users.noreply.github.com> Date: Thu, 17 Sep 2026 11:47:48 +0100 Subject: [PATCH 1/3] fix(monthly-updates): add missing math glyphs for August report MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The 2026-09-01 scheduled run failed because the August Lean sources use three Unicode math glyphs XeLaTeX/DejaVu Sans Mono can't render and that aren't in MISSING_GLYPH_MATH: ⋆ (U+22C6), 𝐚 (U+1D41A), 𝐍 (U+1D40D). Co-Authored-By: Claude Sonnet 5 --- web2/scripts/generate-monthly-updates.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/web2/scripts/generate-monthly-updates.js b/web2/scripts/generate-monthly-updates.js index 8c5ae23..d9c6afc 100644 --- a/web2/scripts/generate-monthly-updates.js +++ b/web2/scripts/generate-monthly-updates.js @@ -965,7 +965,7 @@ const MISSING_GLYPH_MATH = [ ["⟪", "\\langle\\!\\langle"], ["⟫", "\\rangle\\!\\rangle"], ["⟶", "\\longrightarrow"], ["⟹", "\\Longrightarrow"], ["⨂", "\\bigotimes"], ["⨅", "\\bigsqcap"], ["⨯", "\\times"], - ["⬝", "\\cdot"], + ["⬝", "\\cdot"], ["⋆", "\\star"], // Flattened parentheses (U+27EE/U+27EF). ["⟮", "\\lgroup"], ["⟯", "\\rgroup"], // Fraktur letters (U+1D504+ block) - mathlib uses these for ideals and @@ -986,8 +986,8 @@ const MISSING_GLYPH_MATH = [ ["ℰ", "\\mathcal{E}"], // Bold Latin capitals and lowercase (U+1D400+ block). ["𝐃", "\\mathbf{D}"], ["𝐀", "\\mathbf{A}"], ["𝐇", "\\mathbf{H}"], - ["𝐋", "\\mathbf{L}"], ["𝐔", "\\mathbf{U}"], ["𝐩", "\\mathbf{p}"], - ["𝐫", "\\mathbf{r}"], ["𝐱", "\\mathbf{x}"], + ["𝐋", "\\mathbf{L}"], ["𝐍", "\\mathbf{N}"], ["𝐔", "\\mathbf{U}"], ["𝐩", "\\mathbf{p}"], + ["𝐚", "\\mathbf{a}"], ["𝐫", "\\mathbf{r}"], ["𝐱", "\\mathbf{x}"], // Double-struck (blackboard bold, U+1D538+ block) - see also 𝕜 → \Bbbk // above, which has its own dedicated LaTeX command instead of \mathbb. ["𝕂", "\\mathbb{K}"], ["𝕕", "\\mathbb{d}"], From f98414ca9cad8cdf9056c3a3c42b133960ca3753 Mon Sep 17 00:00:00 2001 From: Alex-Zughaid <117576511+Alex-Zughaid@users.noreply.github.com> Date: Thu, 17 Sep 2026 11:49:25 +0100 Subject: [PATCH 2/3] fix(ci): force-push the Vercel mirror from api-map and monthly-updates mirror-to-personal.yml keeps Gabrielebattimelli/Physlib-Website in sync by rewriting commit authorship (filter-branch) and force-pushing, so its history is never a fast-forward descendant of this repo's real commits. The plain `git push mirror` these two workflows also do (needed because GITHUB_TOKEN pushes don't trigger mirror-to-personal.yml) has therefore been rejected as non-fast-forward on every run since at least 2026-08-24, so API map / monthly update commits reached main but never the deployed site. The mirror is a deploy artifact, not shared history, so force is correct here too. Co-Authored-By: Claude Sonnet 5 --- .github/workflows/api-map.yml | 7 ++++++- .github/workflows/monthly-updates.yml | 8 +++++++- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/.github/workflows/api-map.yml b/.github/workflows/api-map.yml index 4fd6d2a..843e263 100644 --- a/.github/workflows/api-map.yml +++ b/.github/workflows/api-map.yml @@ -79,4 +79,9 @@ jobs: git config --global credential.helper store echo "https://x-access-token:${MIRROR_PAT}@github.com" > ~/.git-credentials git remote add mirror https://github.com/Gabrielebattimelli/Physlib-Website.git - git push mirror "HEAD:refs/heads/${GITHUB_REF_NAME}" + # See monthly-updates.yml: mirror-to-personal.yml rewrites authorship + # and force-pushes this same mirror, so its history is never a + # fast-forward descendant of this repo's commits and a plain push + # here is rejected as non-fast-forward. The mirror is a deploy + # artifact, not shared history, so force is correct here too. + git push --force mirror "HEAD:refs/heads/${GITHUB_REF_NAME}" diff --git a/.github/workflows/monthly-updates.yml b/.github/workflows/monthly-updates.yml index d28b334..d933218 100644 --- a/.github/workflows/monthly-updates.yml +++ b/.github/workflows/monthly-updates.yml @@ -156,4 +156,10 @@ jobs: git config --global credential.helper store echo "https://x-access-token:${MIRROR_PAT}@github.com" > ~/.git-credentials git remote add mirror https://github.com/Gabrielebattimelli/Physlib-Website.git - git push mirror "HEAD:refs/heads/${GITHUB_REF_NAME}" + # mirror-to-personal.yml keeps this same mirror in sync by rewriting + # every commit's authorship (filter-branch) and force-pushing the + # result, so the mirror's history is never a fast-forward descendant + # of this repo's real commits - a plain push is rejected as + # non-fast-forward on every run after the first. The mirror is a + # deploy artifact, not shared history, so force is correct here too. + git push --force mirror "HEAD:refs/heads/${GITHUB_REF_NAME}" From a980af13715d2565e99023b100882fcd7c62da3c Mon Sep 17 00:00:00 2001 From: Alex-Zughaid <117576511+Alex-Zughaid@users.noreply.github.com> Date: Thu, 17 Sep 2026 11:50:00 +0100 Subject: [PATCH 3/3] ci(references): schedule generate-references.js like the API map References.json (added in PR #23) had no workflow running it, unlike APIMap.json and the monthly updates: it was generated once for that PR and had no path to staying current. Add a weekly scheduled workflow that mirrors api-map.yml: run the generator, commit if changed, and push to the Vercel mirror. Co-Authored-By: Claude Sonnet 5 --- .github/workflows/references.yml | 84 ++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 .github/workflows/references.yml diff --git a/.github/workflows/references.yml b/.github/workflows/references.yml new file mode 100644 index 0000000..96de7d0 --- /dev/null +++ b/.github/workflows/references.yml @@ -0,0 +1,84 @@ +name: Generate references + +on: + schedule: + # Weekly refresh, same cadence as api-map.yml — docs/references.bib and + # the per-file citation comments it tracks change about as rarely as + # API-map.yaml does. Offset five minutes from api-map.yml's run so the + # two don't start in the same minute. + - cron: "25 4 * * 1" + workflow_dispatch: {} + +permissions: + contents: write + +# Two runs committing to the same branch would race on push. +concurrency: + group: references + cancel-in-progress: false + +jobs: + generate: + runs-on: ubuntu-latest + timeout-minutes: 20 + env: + HAS_MIRROR_PAT: ${{ secrets.MIRROR_PAT != '' }} + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + persist-credentials: true + fetch-depth: 0 + + - name: Set up Node.js + uses: actions/setup-node@v4 + with: + node-version: "20" + + # Shared with the api-map and monthly-updates generators, which also + # read this repo. + - name: Cache physlib clone + uses: actions/cache@v4 + with: + path: web2/.cache/physlib.git + key: physlib-clone-${{ github.run_id }} + restore-keys: physlib-clone- + + - name: Run generator + working-directory: web2 + run: node scripts/generate-references.js + + - name: Commit & push updated references + id: commit + run: | + git config user.name "github-actions[bot]" + git config user.email "41898282+github-actions[bot]@users.noreply.github.com" + git add web2/data/References.json + if git diff --cached --quiet; then + echo "No reference changes to commit." + echo "committed=false" >> "$GITHUB_OUTPUT" + exit 0 + fi + git commit -m "chore(references): auto-generated update" + git pull --rebase --autostash origin "${GITHUB_REF_NAME}" + git push origin "HEAD:${GITHUB_REF_NAME}" + echo "committed=true" >> "$GITHUB_OUTPUT" + + # See monthly-updates.yml for why this step exists: pushes made with the + # default GITHUB_TOKEN don't trigger mirror-to-personal.yml, so without + # this the references page would never reach the deployed (Vercel) site. + - name: Mirror to personal repo (Vercel) + if: steps.commit.outputs.committed == 'true' && env.HAS_MIRROR_PAT == 'true' + env: + MIRROR_PAT: ${{ secrets.MIRROR_PAT }} + run: | + git config --unset-all http.https://github.com/.extraheader || true + git config --global credential.helper store + echo "https://x-access-token:${MIRROR_PAT}@github.com" > ~/.git-credentials + git remote add mirror https://github.com/Gabrielebattimelli/Physlib-Website.git + # See monthly-updates.yml: mirror-to-personal.yml rewrites authorship + # and force-pushes this same mirror, so its history is never a + # fast-forward descendant of this repo's commits and a plain push + # here is rejected as non-fast-forward. The mirror is a deploy + # artifact, not shared history, so force is correct here too. + git push --force mirror "HEAD:refs/heads/${GITHUB_REF_NAME}"