From f64db240606013f6ed7fb4ba15fa4fa5a65466b9 Mon Sep 17 00:00:00 2001 From: cnc Date: Fri, 5 Jun 2026 06:52:42 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8F=82=E8=80=83=E6=89=80=E6=9C=89=E5=88=86?= =?UTF-8?q?=E7=BB=84=EF=BC=8C=E5=AE=8C=E6=88=90=E5=B0=BD=E9=87=8F=E5=A4=9A?= =?UTF-8?q?=E7=9A=84=E5=86=85=E5=AE=B9=EF=BC=9A=E6=94=B6=E7=B4=A7kinematic?= =?UTF-8?q?s=20source-map=E8=BE=B9=E7=95=8C=E5=AE=88=E5=8D=AB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- check-linuxcnc-kinematics-source-map.sh | 16 +++++++++++++++- docs/linuxcnc-kinematics-source-map.md | 10 +++++++++- 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/check-linuxcnc-kinematics-source-map.sh b/check-linuxcnc-kinematics-source-map.sh index 8e2eeac..5ec7701 100755 --- a/check-linuxcnc-kinematics-source-map.sh +++ b/check-linuxcnc-kinematics-source-map.sh @@ -7,7 +7,7 @@ cd "$(dirname "$0")" # with linuxcnc-kinematics-source-files.txt, which enumerates LinuxCNC # kinematics, posemath, switchkins INI/HAL/remap/tooldata/assets, and adjacent # build metadata. It validates source coverage documentation only; it does not -# add or interpret CNC behavior. +# add CNC behavior, expand smoke parsing, or interpret G-code. linuxcnc_root=${LINUXCNC_ROOT:-../linuxcnc} linuxcnc_root=$(cd "$linuxcnc_root" && pwd) @@ -64,6 +64,9 @@ for group in expected_groups: required_phrases = [ "LinuxCNC Source Anchors", + "must not add CNC behavior", + "must not", + "expand the temporary smoke parser", "`src/emc/kinematics/Submakefile`", "`src/emc/kinematics/kinematics.h`", "motion.switchkins-type", @@ -72,12 +75,23 @@ required_phrases = [ "OPFS-only", "derive M428/M429/M430 cases from", "RTCP and five-axis coverage", + "./check-linuxcnc-kinematics-source-map.sh", "./check-linuxcnc-inputs.sh linuxcnc-kinematics-source-files.txt --require-kinematics-complete", "./check-linuxcnc-switchkins-remap-table.sh linuxcnc-kinematics-source-files.txt", + "does not interpret G-code", ] for phrase in required_phrases: if phrase not in source_map: raise SystemExit( f"docs/linuxcnc-kinematics-source-map.md is missing source-coverage boundary phrase: {phrase}" ) + +for entry in [ + "test-native.sh", + "test-linuxcnc-source-link.sh", + "build-wasm.sh", +]: + text = Path(entry).read_text(encoding="utf-8") + if "./check-linuxcnc-kinematics-source-map.sh" not in text: + raise SystemExit(f"{entry} must run ./check-linuxcnc-kinematics-source-map.sh") PY diff --git a/docs/linuxcnc-kinematics-source-map.md b/docs/linuxcnc-kinematics-source-map.md index 5e18304..e96651a 100644 --- a/docs/linuxcnc-kinematics-source-map.md +++ b/docs/linuxcnc-kinematics-source-map.md @@ -3,7 +3,8 @@ This map tracks the LinuxCNC source/configuration basis for kinematics, switchkins, RTCP, and M428/M429/M430 remap coverage. It is intentionally a source-coverage document: the manifest entries here must not become browser or -application behavior by themselves. +application behavior by themselves. It must not add CNC behavior and must not +expand the temporary smoke parser. ## Manifest groups @@ -44,6 +45,11 @@ groups: LinuxCNC INI/HAL/remap sources, not from hand-authored behavior. - RTCP and five-axis coverage must remain tied to LinuxCNC kinematics sources, remap files, and configuration files. +- `test-native.sh`, `test-linuxcnc-source-link.sh`, and `build-wasm.sh` must + run `./check-linuxcnc-kinematics-source-map.sh` before consuming generated + config aliases, source-linked LinuxCNC objects, or browser artifacts. +- The kinematics source-map guard validates LinuxCNC source/config ownership + and manifest drift only; it does not interpret G-code. ## Checks @@ -53,6 +59,8 @@ Run: ./check-linuxcnc-kinematics-source-map.sh ./check-linuxcnc-inputs.sh linuxcnc-kinematics-source-files.txt --require-kinematics-complete ./check-linuxcnc-switchkins-remap-table.sh linuxcnc-kinematics-source-files.txt +./test-native.sh +./test-linuxcnc-source-link.sh ``` `check-linuxcnc-kinematics-source-map.sh` keeps this document's group counts in