mirror of
https://github.com/margrop/wrong-notebook.git
synced 2026-12-05 07:29:27 +08:00
- start-stop-status 改用 curl -sf 并校验 status=ok,404/500/503 不再误报运行中 - 证书目录支持 CERT_DIR,非 root 且 /app/certs 不可写时回退到 CONFIG_DIR/certs - 群晖 compose 补充 WN_PLATFORM 与日志轮转,CI 覆盖全部 NAS 脚本语法检查 - 新增 tests/publication/test_nas_packaging.py 验证健康状态与打包配置
23 lines
921 B
Bash
Executable File
23 lines
921 B
Bash
Executable File
#!/usr/bin/env bash
|
|
set -euo pipefail
|
|
cd "$(dirname "$0")/.."
|
|
|
|
if (( $(node -p 'process.versions.node.split(".")[0]') < 22 )); then
|
|
echo "CI requires Node.js 22 or later." >&2
|
|
exit 1
|
|
fi
|
|
export NEXT_TELEMETRY_DISABLED=1
|
|
export DATABASE_URL="${DATABASE_URL:-file:./ci.db}"
|
|
npm ci --no-audit --no-fund
|
|
npx --no-install prisma generate
|
|
npm run lint
|
|
npm test
|
|
python3 -m unittest discover -s tests/publication -v
|
|
python3 scripts/check-public-history.py HEAD
|
|
bash -n scripts/ci.sh scripts/build-image.sh
|
|
sh -n docker-entrypoint.sh
|
|
for f in packaging/runtime/launcher.js packaging/npm/bin/wrong-notebook.js packaging/desktop/main.js scripts/package/build.mjs; do node --check "$f"; done
|
|
for f in packaging/fnos/cmd/*; do bash -n "$f"; done
|
|
for f in packaging/docker/docker-container.sh packaging/qnap/package_routines packaging/qnap/shared/wrongnotebook.sh packaging/synology/scripts/*; do sh -n "$f"; done
|
|
npm run build
|