Token导航 LogoToken导航

Agent Skill · 开发

github-pages(GitHub pages 开发)

用于围绕 GitHub 仓库、Issue、Pull Request、分支、提交和代码协作流程提供辅助能力。它适合让 Agent 查询项目状态、整理变更、辅助创建或检查协作事项,并把仓库中的信息转成可执行的下一步。使用时需要区分只读查询和写入操作;涉及创建 PR、修改 Issue、推送分支或访问私有仓库时,应确认 token 权限、目标仓库范围和用户授权。

github-pages 是开发类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为需要联网;许可证信息还不明确,第三方扫描已通过,按安装量在开发类的 21,746 个 Skill 里排第 4,953。

总安装 7,244周安装 237GitHub Stars 1下载 2,829核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:github-pages(GitHub pages 开发)
来源仓库:https://github.com/alfredang/skills
仓库路径:skills/github-pages
安装命令:
npx skills add https://github.com/alfredang/skills --skill 'GitHub Pages'
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/alfredang/skills --skill 'GitHub Pages'

这个 Skill 是做什么的

开发类 Skill 面向写代码、改代码和排查问题,一般会读写仓库文件,部分还会执行构建或测试命令。

用于管理和部署 GitHub Pages 静态网站。支持自动构建和发布流程。github-pages 属于开发类 Skill,可作为该场景下的辅助能力补充。可配置自定义域名和 HTTPS。适合个人作品展示和文档托管。免费版有流量和存储限制。

适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。

来源仓库内路径:skills/github-pages

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/alfredang/skills --skill 'GitHub Pages';命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要需要联网,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

github-pages 怎么安装?

在终端执行 npx skills add https://github.com/alfredang/skills --skill 'GitHub Pages'。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

github-pages 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

github-pages 需要什么权限?

权限级别是需要联网。该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

github-pages 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

github-pages 用的人多吗?

公开数据是累计安装 7,244 次,近一周安装 237 次,下载 2,829 次,GitHub 1 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

github-pages 安全吗?

第三方扫描结果为通过,但这只覆盖已知的静态检查项,不能替代自己读一遍源码和安装命令。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 第三方扫描已通过,常见的高风险行为没有命中。

先想清楚的地方

  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理开发类任务、又不想每次都手写提示词的人。

不太适合

  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

开发类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
skill-vetter

技能审查员 · OpenClaw

8,779,018986操作浏览器MIT-0通过
ontology

本体论 · OpenClaw

6,636,960576只读MIT-0通过
entra-app-registration

内部应用程序注册 · Codex、Claude

6,631,872764接触敏感数据未明确通过
entra-app-registration

内部应用程序注册 · Codex、Claude

3,757,680201接触敏感数据未明确通过
nano-banana-pro

纳米香蕉专业版 · OpenClaw

3,526,898364接触敏感数据MIT-0有提醒
github-pages

GitHub pages 开发 · 本页

7,2441需要联网未明确通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

GitHub Pages Deployment

Command

/github-page or github-page

Navigate

Deployment

Keywords

github pages, deploy pages, static site, gh-pages, github actions, deploy website, host website, github hosting, deploy static, pages deploy, free hosting, github site, publish site, deploy html, deploy react to github

Description

Deploy any project to GitHub Pages with zero manual configuration. Automatically detects your project type, generates the correct GitHub Actions workflow, enables GitHub Pages and Actions on the repo via API, and gives you a live URL.

Execution

This skill runs using Claude Code with subscription plan. Do NOT use pay-as-you-go API keys. All AI operations should be executed through the Claude Code CLI environment with an active subscription.

Response

I'll help you deploy to GitHub Pages!

The workflow includes:

StepDescription
Pre-flightVerify gh CLI, git remote, and repo access
Detect ProjectAuto-detect project type and build config
Generate WorkflowCreate .github/workflows/deploy-pages.yml
Push & EnablePush workflow, enable GitHub Pages + Actions via API
VerifyConfirm deployment and provide live URL

Instructions

When executing /github-page, follow this workflow:

Phase 1: Pre-flight Checks

1.1 Verify GitHub CLI
gh --version

If not installed, inform the user:

ERROR: GitHub CLI (gh) not found.
Install: https://cli.github.com/
1.2 Verify Authentication
gh auth status

If not authenticated:

ERROR: Not logged in to GitHub CLI.
Run: gh auth login
1.3 Verify Git Remote
git remote get-url origin

Extract OWNER and REPO from the remote URL:

# For HTTPS: https://github.com/OWNER/REPO.git
# For SSH: git@github.com:OWNER/REPO.git
REMOTE_URL=$(git remote get-url origin)
OWNER=$(echo "$REMOTE_URL" | sed -E 's#.*(github\.com)[:/]([^/]+)/([^/.]+)(\.git)?$#\2#')
REPO=$(echo "$REMOTE_URL" | sed -E 's#.*(github\.com)[:/]([^/]+)/([^/.]+)(\.git)?$#\3#')

If no remote exists:

ERROR: No GitHub remote found.
Add one with: git remote add origin https://github.com/USER/REPO.git

Phase 2: Detect Project Type

Analyze the project to determine build commands and output directory.

2.1 Detection Rules
IndicatorProject TypeBuild CommandOutput Dir
vite.config.*Vite (React/Vue/Svelte)npm install && npm run build./dist
next.config.*Next.js (static export)npm install && npm run build./out
angular.jsonAngularnpm install && npm run build./dist/<project>
package.json with build scriptNode.js projectnpm install && npm run build./dist or ./build
index.html in rootStatic HTMLNone./
public/index.htmlStatic in public/None./public
requirements.txt + mkdocs.ymlMkDocspip install -r requirements.txt && mkdocs build./site
None of the aboveUnknownAsk userAsk user
2.2 Framework-Specific Configuration

Vite projects — Ensure base is set in vite.config.*:

export default defineConfig({
  base: '/<REPO>/',
})

Inform the user if base is not set — the site will have broken asset paths without it.

Next.js projects — Ensure output: 'export' is in next.config.*:

const nextConfig = {
  output: 'export',
  basePath: '/<REPO>',
}
2.3 Node.js Version Detection

Check for .nvmrc, .node-version, or engines.node in package.json to set the correct Node.js version in the workflow. Default to 20 if not specified.

Phase 3: Generate GitHub Actions Workflow

Create .github/workflows/deploy-pages.yml:

3.1 Static HTML (No Build Step)
name: Deploy to GitHub Pages

on:
  push:
    branches: [main]
  workflow_dispatch:

permissions:
  contents: read
  pages: write
  id-token: write

concurrency:
  group: "pages"
  cancel-in-progress: false

jobs:
  deploy:
    environment:
      name: github-pages
      url: ${{ steps.deployment.outputs.page_url }}
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v4

      - name: Setup Pages
        uses: actions/configure-pages@v5

      - name: Upload artifact
        uses: actions/upload-pages-artifact@v4
        with:
          path: '.'

      - name: Deploy to GitHub Pages
        id: deployment
        uses: actions/deploy-pages@v4
3.2 Node.js Project (React/Vite/Next.js/Angular)
name: Deploy to GitHub Pages

on:
  push:
    branches: [main]
  workflow_dispatch:

permissions:
  contents: read
  pages: write
  id-token: write

concurrency:
  group: "pages"
  cancel-in-progress: false

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v4

      - name: Setup Node.js
        uses: actions/setup-node@v4
        with:
          node-version: '<NODE_VERSION>'
          cache: 'npm'

      - name: Install dependencies
        run: npm ci

      - name: Build
        run: npm run build

      - name: Setup Pages
        uses: actions/configure-pages@v5

      - name: Upload artifact
        uses: actions/upload-pages-artifact@v4
        with:
          path: '<OUTPUT_DIR>'

  deploy:
    environment:
      name: github-pages
      url: ${{ steps.deployment.outputs.page_url }}
    runs-on: ubuntu-latest
    needs: build
    steps:
      - name: Deploy to GitHub Pages
        id: deployment
        uses: actions/deploy-pages@v4

Replace <NODE_VERSION> and <OUTPUT_DIR> with detected values from Phase 2.

3.3 Create the Workflow File
mkdir -p .github/workflows

Write the appropriate workflow YAML to .github/workflows/deploy-pages.yml.

Phase 4: Enable GitHub Pages & Actions (Auto-configure)

4.1 Commit and Push the Workflow
git add .github/workflows/deploy-pages.yml
git commit -m "$(cat <<'EOF'
ci: add GitHub Pages deployment workflow

Co-Authored-By: Claude <noreply@anthropic.com>
EOF
)"
git push origin main

Important: Always add specific files. Never use git add. or git add -A.

4.2 Enable GitHub Pages via API

First, check if Pages is already enabled:

gh api "/repos/$OWNER/$REPO/pages" 2>/dev/null

If not enabled (404 response), create it:

gh api -X POST "/repos/$OWNER/$REPO/pages" -f build_type=workflow

If already enabled but using a different source, update it:

gh api -X PUT "/repos/$OWNER/$REPO/pages" -f build_type=workflow
4.3 Enable the Workflow
gh workflow enable deploy-pages.yml
4.4 Trigger Initial Deployment (if push didn't trigger it)
gh workflow run deploy-pages.yml

Phase 5: Verify & Report

5.1 Check Workflow Run

Wait a few seconds, then check:

gh run list --workflow=deploy-pages.yml --limit 1
5.2 Print Results
=== GitHub Pages Deployment ===

Workflow: .github/workflows/deploy-pages.yml (created)
GitHub Pages: ENABLED (source: GitHub Actions)
GitHub Actions: ENABLED

Deployment URL: https://<OWNER>.github.io/<REPO>/
Workflow runs: https://github.com/<OWNER>/<REPO>/actions

Status: Deploying... (check Actions tab for progress)
5.3 If Errors Occur

Pages API returns 409 (conflict):

  • Pages may already be configured with a branch source
  • Update with PUT instead of POST

Workflow not triggering:

  • Ensure the branch name matches (main vs master)
  • Check if Actions are enabled at the repo level: gh api -X PUT "/repos/$OWNER/$REPO/actions/permissions" -f enabled=true

Build fails:

  • Check the workflow run logs: gh run view --log
  • Common issues: missing base config for Vite, missing output: 'export' for Next.js

Capabilities

  • Auto-detect project type (static HTML, React, Vite, Next.js, Angular, MkDocs)
  • Generate correct GitHub Actions workflow for the project
  • Enable GitHub Pages with Actions source via API
  • Enable GitHub Actions on the repo automatically
  • Trigger initial deployment
  • Support for custom build commands and output directories
  • Node.js version detection from project config

Next Steps

After running /github-page:

  1. Check the Actions tab: https://github.com/<OWNER>/<REPO>/actions
  2. Wait for the first deployment to complete (usually 1-2 minutes)
  3. Visit your live site: https://<OWNER>.github.io/<REPO>/
  4. For custom domains, configure in repo Settings > Pages > Custom domain
  5. Future pushes to main will auto-deploy via the workflow

平台分布

Codex

36.44%
按下载量换算1,031

Claude

33.03%
按下载量换算934

Cursor

17.86%
按下载量换算505

Gemini CLI

9.99%
按下载量换算283

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills