360 Secure SkillHub
360 安全技能中心

Statichub

该 Skill 指导使用 StaticHub CLI 部署 AI 生成的静态资源:先检查或安装 CLI,再校验目标为非空目录或非空 .html 文件,随后以命名或匿名方式执行部署,成功后返回访问 URL 与子域名。

patrick0308
patrick0308
热度 25.93
最近更新 2026-05-25 19:57:21
分类:自动化依赖:代码执行 / 第三方 API / 读写文件应用场景:工作流 / DevOps / 自动化脚本

安装技能

复制下面的话术发给你的 Agent,它会通过 secure-skills 检索并安装该技能。

执行命令安装此 skill: npx secure-skills-cli add statichub
Metadata
name
statichub
description
Deploy AI-generated static assets with StaticHub CLI. Use when a user wants to publish files with `statichub deploy <path>`, where `<path>` must be an explicit non-empty directory or a non-empty `.html` file.

StaticHub

Rules

  1. Always use an explicit path: statichub deploy <path>.
  2. Never default to ..
  3. Accept only:
    • existing non-empty directory, or
    • existing non-empty .html file.
  4. If validation fails, stop and return repair commands.
  5. If project name exists, use --name; otherwise deploy anonymously.

Steps

  1. Check CLI:
    • command -v statichub
    • statichub --help
    • If missing, install with one line:
      • curl -sSL https://raw.githubusercontent.com/Patrick0308/statichub/main/scripts/install.sh | sh
  2. Validate <path> exists and is valid.
  3. Run deploy:
    • Named: statichub deploy <path> --name <project>
    • Anonymous: statichub deploy <path>
  4. On success, return URL and Subdomain.

Real Example

Command:

  • statichub deploy ~/Downloads/eks-cost-optimization-roadmap.html

Output:

✅ Deploy successful!
   URL: http://b7kr7b.statichub.dev
   Subdomain: b7kr7b

The URL value is the live page URL.