Install
openclaw skills install @pankitgg/oia-skill使用 oia 框架(npm 包 @oia-ai/oia-fresh)初始化全栈项目。当用户要求「创建 oia 项目」「初始化 oia / oia-fresh」「用 oia 框架搭一个应用」时触发。 译文:Init project with OIA (@oia-ai/oia-fresh). Trigger on "create OIA project", "init oia-fresh", "build with OIA". Includes env check, npx init, dev server & verify.
openclaw skills install @pankitgg/oia-skilloia 框架以 @oia-ai/oia-fresh 为名发布在 npm 仓库,初始化命令为 npx @oia-ai/oia-fresh init。
生成的项目基于 Deno + Fresh 2(Vite 构建),开发服务器端口为 5173。
本 skill 自身也发布为 npm 包 @oia-ai/oia-skill,安装方式:
npx -y @oia-ai/oia-skill # 安装到当前项目
npx -y @oia-ai/oia-skill --global # 安装到用户目录(所有项目可用)
deno --version:要求 Deno 2.x。未安装时引导安装:
winget install Denoland.Denocurl -fsSL https://deno.land/install.sh | shnpx --version:确认 Node / npx 可用(仅用于执行 init 脚本,项目运行不依赖 Node)。在期望放置项目的父目录下执行:
npx -y @oia-ai/oia-fresh@latest init <项目名>
注意事项:
npx -y @oia-ai/oia-fresh@latest init . 在当前目录直接释放模板(不删除已有文件,仅写入/覆盖模板文件,.git 等一律保留)。npm_config_proxy=http://127.0.0.1:<端口> npm_config_https_proxy=http://127.0.0.1:<端口> npx ... 重试。cd <项目名>
deno task dev # 后台启动
轮询 http://127.0.0.1:5173/ 直到返回 HTTP 200,确认页面内容正常后停掉后台服务器,向用户汇报验证结果。
deno task dev;生产 deno task build 后 deno task start。deno.lock;deno.json 使用 nodeModulesDir: manual,不要手动删除 node_modules/。