Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions .github/workflows/ci-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: CI - Build

on:
push:
branches: [main]
pull_request:

concurrency:
group: ci-build-${{ github.ref }}
cancel-in-progress: true

permissions:
contents: read

jobs:
workspace:
name: Build workspace
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
with:
submodules: recursive

- uses: j178/prek-action@v3.0.0

Check failure on line 24 in .github/workflows/ci-build.yml

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Use full commit SHA hash for this dependency.

See more on https://sonarcloud.io/project/issues?id=zrr1999_zrr.dev&issues=AaE_VyEChqYb7BjiFxrG&open=AaE_VyEChqYb7BjiFxrG&pullRequest=82
with:
install-only: true

- uses: voidzero-dev/setup-vp@v1

Check failure on line 28 in .github/workflows/ci-build.yml

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Use full commit SHA hash for this dependency.

See more on https://sonarcloud.io/project/issues?id=zrr1999_zrr.dev&issues=AaE_VyEChqYb7BjiFxrH&open=AaE_VyEChqYb7BjiFxrH&pullRequest=82
with:
cache: true
run-install: |
args: ["--frozen-lockfile"]

- name: Build all sites
run: vp run build
2 changes: 0 additions & 2 deletions .github/workflows/ci-links.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ on:
- "README.md"
- ".github/workflows/ci-links.yml"
pull_request:
branches:
- main
paths:
- "AGENTS.md"
- "README.md"
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/ci-static-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@
branches:
- main
pull_request:
branches:
- main

concurrency:
group: ci-static-${{ github.ref }}
Expand All @@ -22,7 +20,7 @@
steps:
- uses: actions/checkout@v7

- uses: j178/prek-action@v3.0.0

Check failure on line 23 in .github/workflows/ci-static-checks.yml

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Use full commit SHA hash for this dependency.

See more on https://sonarcloud.io/project/issues?id=zrr1999_zrr.dev&issues=AaE_VyBGhqYb7BjiFxrE&open=AaE_VyBGhqYb7BjiFxrE&pullRequest=82
with:
install-only: true

Expand All @@ -30,4 +28,4 @@
with:
cache: true

- uses: j178/prek-action@v3.0.0

Check failure on line 31 in .github/workflows/ci-static-checks.yml

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Use full commit SHA hash for this dependency.

See more on https://sonarcloud.io/project/issues?id=zrr1999_zrr.dev&issues=AaE_VyBGhqYb7BjiFxrF&open=AaE_VyBGhqYb7BjiFxrF&pullRequest=82
2 changes: 0 additions & 2 deletions .github/workflows/ci-typos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@ on:
- "README.md"
- "apps/blog/data/blog/**"
pull_request:
branches:
- main
paths:
- ".github/**"
- ".vale.ini"
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/ci-vale.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ on:
- "hosting"
- "hosting/**/*.md"
pull_request:
branches:
- main
paths:
- ".vale.ini"
- ".github/styles/**"
Expand Down
10 changes: 10 additions & 0 deletions apps/blog/astro.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,16 @@ export default defineConfig({
typst({
options: {
remPx: 14,
cheerio: {
postprocess($, source) {
if ($("svg").length === 0) {
throw new Error(
`Typst produced no SVG for ${source.mainFilePath}. Check the compiler diagnostics above.`

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

非阻塞:astro-typst 的 prepareSource 对字符串输入只生成 { mainFileContent },此时 mainFilePath 为 undefined。可改为 source.mainFilePath ?? "inline Typst content",让报错信息总能指向具体来源。

);
}
return $;
},
},
},
target: id => {
if (id.includes("/data/")) return "html";
Expand Down
2 changes: 1 addition & 1 deletion apps/blog/data/blog/_language/egglog-quickstart-02.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ modDatetime: 2026-02-15
tags: ["编译/IR", "E-graph", "egg", "egglog", "等价饱和", "Term Rewriting"]
---

[第一篇](egglog-quickstart-01) 用 Peano 构造和纯重写规则定义了自然数的加法与乘法。本文从自然数出发,**逐步扩展**到整数与有理数,在此过程中展示 `constructor` 扩展、`rule`、`:when`、`relation`、`birewrite` 等 egglog 特性。第三篇将介绍内置类型,并以复数为例展示其应用。
[第一篇](/posts/egglog-quickstart-01/) 用 Peano 构造和纯重写规则定义了自然数的加法与乘法。本文从自然数出发,**逐步扩展**到整数与有理数,在此过程中展示 `constructor` 扩展、`rule`、`:when`、`relation`、`birewrite` 等 egglog 特性。第三篇将介绍内置类型,并以复数为例展示其应用。

## 从自然数到整数:引入 Neg

Expand Down
2 changes: 1 addition & 1 deletion apps/blog/data/blog/_language/egglog-quickstart-03.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ modDatetime: 2026-02-17
tags: ["编译/IR", "E-graph", "egg", "egglog", "等价饱和", "Term Rewriting"]
---

[第二篇](egglog-quickstart-02) 用纯构造从自然数扩展到整数、有理数与实数。本文**承接第二篇**:先用已有类型定义复数及其运算,再介绍 egglog 的**内置类型**,并展示如何用它们实现高效运算。
[第二篇](/posts/egglog-quickstart-02/) 用纯构造从自然数扩展到整数、有理数与实数。本文**承接第二篇**:先用已有类型定义复数及其运算,再介绍 egglog 的**内置类型**,并展示如何用它们实现高效运算。

## 复数的纯构造定义

Expand Down
Loading