feat: update desktop workflows and app center

This commit is contained in:
inman
2026-05-13 19:14:56 +08:00
parent 20b5aff4ad
commit 7c8781a6e3
160 changed files with 55492 additions and 1423 deletions

View File

@@ -108,7 +108,14 @@ const runtimePolicies = new Map([
- Do not ask the user to install desktop office suites or unrelated external GUI tools.
- Use the Python/HTML/PDF workflows in this skill and keep outputs in project-accessible local paths.
- When running Python scripts, prefer \`uv run python\`. If a Python dependency is missing, use \`uv pip install\` instead of asking the user to install it manually.
- If an optional renderer is unavailable, choose another supported path or report the limitation only when it directly blocks the requested output.
- If an optional browser renderer is unavailable, choose another supported path or report the limitation only when it directly blocks the requested output.
- Never run task-time Playwright or Chromium installers inside a user task. Chromium is prepared by the app/runtime layer; task-time browser downloads can collide with other runs.
`],
['html-slides', `## Zhinian Runtime Policy
- Use the project/app-bundled browser runtime for optional preview checks.
- Never run \`npx playwright install chromium\`, \`playwright install chromium\`, or \`npm install -g playwright\` inside a user task.
- If browser preview is unavailable, validate the deck by static file checks and report that browser preview was skipped. Do not block deck delivery on a task-time Chromium download.
`],
]);
@@ -318,6 +325,10 @@ if __name__ == "__main__":
.replace(/`npm install -g docx`/g, 'use the project-bundled `docx` module when available')
.replace(/`npm install -g pptxgenjs`/g, 'use the project-bundled `pptxgenjs` module')
.replace(/`npm install -g playwright`/g, 'use the project-bundled Playwright runtime when available')
.replace(/`npx playwright install chromium`/g, 'use the project-bundled Chromium browser when available')
.replace(/`playwright install chromium`/g, 'use the project-bundled Chromium browser when available')
.replace(/\bnpx\s+playwright\s+install\s+chromium\b/g, 'use the project-bundled Chromium browser when available')
.replace(/\bplaywright\s+install\s+chromium\b/g, 'use the project-bundled Chromium browser when available')
.replace(/`npm install -g react-icons react react-dom`/g, 'use project-bundled `react-icons`, `react`, and `react-dom`')
.replace(/`npm install -g sharp`/g, 'use the project-bundled `sharp` module when available')
.replace(/`pip install defusedxml`/g, '`uv pip install defusedxml`')