local-project-runtime
安装方式
先用 Prompt 核对来源与依赖。也可下载安装包。
用 AI 助手安装
复制提示词,让助手先核对固定版本和依赖。
查看 Prompt收起 Prompt
先检查当前 Agent 是否已安装 SkillPI Skill Finder。如果尚未安装,请按官方仓库的说明安装并启用:https://github.com/Findskills/skillpi。然后使用 Skill Finder 打开此 SkillPI 详情页并定位 "local-project-runtime":https://skillpi.com/zh/skills/deepskill-727c1fc00917d01b8c2d0db454012ba03ff5447e665eab8a9475fbecd48ae585。安装前核对上游来源和版本:https://github.com/penwyp/ClaudePreference。来源不一致时停止并说明差异。核对通过后,用 Skill Finder 安装目标 Skill,并报告安装路径和来源版本。
来源与配置
github.com
配置方式待核实
请查看原始来源中的适用工具、依赖和权限要求。
安装实测待补充
在克隆或检出代码后,诊断并稳定本地项目设置。适用于需要可重复的构建/启动/测试/生命周期工作流、Docker Compose 管理、端口选择或构建缓存的仓库。
介绍来源: third_party · penwyp · 0.0.1 参考来源
SkillPi 解读
- 能完成的任务
- 翻译待完成,请参阅来源文档。
- 实测状态
- 未测试
文件浏览
Frontmatter
name: local-project-runtime
description: Diagnose and stabilize local project setup after clone or checkout. Use when a repo needs repeatable build/start/test/lifecycle workflows, Docker Compose management, port selection, or build caching.Local Project Runtime
Use this skill to turn an unknown repository into a locally manageable project with predictable build, start, test, logs, health, and cleanup commands.
Core Workflow
-
Inspect first:
- Read root docs and manifests:
README*,AGENTS.md,package.json, lockfiles,Dockerfile, Compose files, Makefile, task runner configs, CI workflows. - Identify the package manager, runtime, service entrypoint, frontend directories, backend directories, DB/external dependencies, default ports, and health endpoints.
- Check current worktree state before editing.
- Read root docs and manifests:
-
Reproduce narrowly:
- Run the smallest relevant command for the reported failure.
- Capture the exact failing phase: dependency install, typecheck/compile, frontend bundle, Docker image build, container boot, health probe, migration, or test runner.
- Prefer targeted checks before repo-wide verification.
-
Fix architecture, not symptoms:
- Keep build/start/test contracts in one local runtime surface, normally
deploy/local/. - Avoid one-off shell notes that cannot be rerun.
- Make generated scripts explicit, idempotent, and safe when services are absent.
- Keep build/start/test contracts in one local runtime surface, normally
-
Add or repair a lifecycle manager:
- Required commands:
init,deps,build,test,image,start,apply,restart,stop,status,logs,ps,clean,doctor. startcreates services and waits for health.applyrebuilds the image and force-recreates the service.restartrestarts an existing container; if none exists, it must start instead of doing an empty restart.statusmust show Compose state and HTTP health.cleanmust stop services and remove local runtime data only.
- Required commands:
-
Add build acceleration where justified:
- For Node/monorepos, add a local build wrapper that hashes frontend inputs and skips frontend production bundling when unchanged.
- Preserve correctness by hashing lockfiles, frontend source/config/public assets, and shared packages imported by the frontend.
- For Docker, split frontend build into its own layer before backend/application
COPY . .so backend-only changes reuse frontend layers. - Update
.dockerignoreto exclude local build artifacts and caches.
-
Add port and health decisions:
- Keep host port in
deploy/local/.env; generate it from.env.exampleor defaults. - For a new lifecycle manager, do not default to port 3000. Allocate a random free host port from
[30-300] * 100while excluding3000, effectively3100, 3200, ... 30000. - If
deploy/local/runtime/control.shalready exists anddeploy/local/.envor.env.examplealready contains a host port, keep that port and do not allocate a new one. - If the configured host port is occupied and the project service is not already running, auto-select another free port from the same
[30-300] * 100pool and update public URL. - Probe health with a bounded retry loop and print recent service logs on failure.
- Use concrete URLs in handoff.
- Keep host port in
-
Verify end to end:
- Syntax-check generated scripts.
- Validate Compose config.
- Run first build and a second build to prove cache behavior if caching was added.
- Start or apply the service and verify HTTP health.
- Run relevant tests or report why tests were not run.
Bundled Resources
- For lifecycle script semantics and command contracts, read
references/lifecycle-manager.md. - For frontend compile speed, task caching, Docker layer caching, and invalidation rules, read
references/build-cache.md. - For build/start/test failure triage patterns, read
references/diagnostics.md. - For Node/PNPM/NPM/Yarn projects, run or adapt:
node skills/local-project-runtime/scripts/scaffold-node-runtime.mjs --help
The scaffold script is a starting point, not a substitute for repo inspection. Review generated files before final handoff and adjust commands, ports, health paths, service names, and Dockerfile behavior to match the project.
当前收录版本
0.0.1
安全与评测信息
质量评测
满分100 · 来自 SkillPi LAB 实验室的评测报告。
亮点
- 解决本地项目克隆后构建/启动/测试等高频刚需场景
- 提供可重复的生命周期工作流管理,显著提升开发效率
亮点
- 触发词精准完整,覆盖多种项目类型和场景变体
- 边界清晰,不易与其他 Skill 重叠
亮点
- Phase/步骤清晰,包含完整的端到端验证流程
- frontmatter 完整,文档结构规范易读
亮点
- 工具来源明确,参数设计合理
- 覆盖主要异常场景(端口占用、健康探测失败)
- 不可逆操作有安全限制(clean 仅移除本地数据)
取前四项原始分值的算术平均,四舍五入取整。可通过收录报告核对各项评分与说明,运行记录需单独查证。
正文静态检测
100 / 100 · skillpi-20261123-no-r3-v1
正文未命中当前规则。
分数仅反映正文中的规则命中,供使用前参考。附件与运行行为不在此评分范围内。
权限与使用前检查
根据当前主文档自动整理,命中内容可能是示例或防护说明;不是实际权限声明,也未覆盖附件、外部依赖或运行行为。
未从主文档识别到上述常见操作,不能据此判断无需权限或没有风险。
安全评级与访问范围
safe · 静态证据核验,不代表运行安全保证。
使用前请由宿主核对并授权实际文件读写、外部服务和联网目的地;本站的核验不会授予任何运行权限。
用户讨论
还没有已核实的点评。