diff --git a/.dockerignore b/.dockerignore deleted file mode 100644 index 7a8a070..0000000 --- a/.dockerignore +++ /dev/null @@ -1,13 +0,0 @@ -.git -node_modules -.codex -.claude -.cache -dist -artifacts -data -__pycache__ -**/__pycache__ -*.log -.env -.env.* diff --git a/.gitea/workflows/verify.yml b/.gitea/workflows/verify.yml deleted file mode 100644 index 32ce198..0000000 --- a/.gitea/workflows/verify.yml +++ /dev/null @@ -1,28 +0,0 @@ -name: Shanhe source and offline package checks -on: - pull_request: - branches: [main] - push: - branches: [main] -concurrency: - group: shanhe-${{ gitea.event.pull_request.number || gitea.ref }} - cancel-in-progress: true -jobs: - verify: - runs-on: ces-control - timeout-minutes: 60 - steps: - - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - name: Check patch formatting - run: git diff --check HEAD^ HEAD - - name: Build isolated verification image - run: docker build -f Dockerfile.ci -t "shanhe-check:${{ gitea.sha }}" . - - name: Verify unit tests and offline package - run: docker run --rm "shanhe-check:${{ gitea.sha }}" - - name: Remove this verification image while retaining parent cache - if: always() - run: | - image="shanhe-check:${{ gitea.sha }}" - if docker image inspect "$image" >/dev/null 2>&1; then docker image rm --no-prune "$image"; fi diff --git a/Dockerfile.ci b/Dockerfile.ci deleted file mode 100644 index 532f6ef..0000000 --- a/Dockerfile.ci +++ /dev/null @@ -1,8 +0,0 @@ -FROM node:24-bookworm -RUN apt-get update && apt-get install -y --no-install-recommends python3 ca-certificates && rm -rf /var/lib/apt/lists/* -WORKDIR /app -COPY package.json package-lock.json ./ -RUN npm ci -COPY . . -RUN python3 scripts/prepare-ci-audit.py -CMD ["sh", "-c", "npm test && npm run build"] diff --git a/README.md b/README.md index 7ce642a..78f7942 100644 --- a/README.md +++ b/README.md @@ -273,6 +273,3 @@ npm run build 测试覆盖直接全量正向、保持位置/平移速度、不调用碰撞试算、新块与之后自由转动、无后台重试、贴地不挪动、暂停/结束/尺寸变化以及真实湖北/成都多轮晃动的物理推进。历史章节中的自动模式仅为先前版本记录,以本节和当前源码为准。 -## 远程源码同步检查 - -Gitea 的 `verify.yml` 在已确认的 `ces-control` 上通过 Docker 执行单元测试、离线构建、地图完整性及打包审计。官方 1.8.0 审计器由 CI 从官方地址读取并核对固定 SHA-256;本机 `.codex`、缓存和旧构建产物不进入镜像。依赖未变时复用安装层,检查镜像清理保留父层缓存。浏览器、创服模拟器与真机验证不由这项 CI 代替。 diff --git a/scripts/prepare-ci-audit.py b/scripts/prepare-ci-audit.py deleted file mode 100644 index c6a89db..0000000 --- a/scripts/prepare-ci-audit.py +++ /dev/null @@ -1,19 +0,0 @@ -"""Install only the pinned official package auditor inside the remote CI image.""" -import hashlib -import io -from pathlib import Path -import urllib.request -import zipfile - -url = 'https://fe-static.xhscdn.com/minitool/20261015161653/minitool-zip-builder-1.8.0.skill' -with urllib.request.urlopen(url, timeout=120) as response: - archive = zipfile.ZipFile(io.BytesIO(response.read())) - matches = [name for name in archive.namelist() if name.endswith('scripts/audit_artifact.py')] - if len(matches) != 1: - raise SystemExit('Official auditor missing or ambiguous') - content = archive.read(matches[0]) -if hashlib.sha256(content).hexdigest() != '62ff11eae1d5bb566a6f74b0fa102fe2eb3ffe982b87596aca2f93485cc9de21': - raise SystemExit('Official auditor changed; review before updating the pinned checksum') -target = Path('.codex/skills/minitool-zip-builder/scripts/audit_artifact.py') -target.parent.mkdir(parents=True, exist_ok=True) -target.write_bytes(content)