name: web-deploy-github description: Create and deploy single-page static websites to GitHub Pages with autonomous workflow. Use when building portfolio sites, CV pages, landing pages, or any static web project that needs GitHub Pages deployment. Handles complete workflow from project initialization to live deployment with GitHub Actions automation.
This skill enables autonomous creation and deployment of static websites to GitHub Pages. It follows a complete workflow from project structure initialization through automatic deployment via GitHub Actions, optimized for single-page applications, portfolios, and landing pages.
Create the project structure:
bash scripts/init_project.sh <project-name>
This creates:
project-name/
├── index.html
├── styles.css
├── script.js
├── README.md
└── .github/
└── workflows/
└── deploy.yml
Build the website following these principles: - Single-page first: Optimize for one-page layouts unless multiple pages explicitly required - Autonomous generation: Generate complete, production-ready code without placeholders - Modern design: Use modern CSS (flexbox, grid), responsive design, clean aesthetics - No dependencies: Pure HTML/CSS/JS when possible, CDN links if frameworks needed
Use templates from assets/templates/ as starting points:
- base-html/ - Minimal HTML5 boilerplate
- portfolio/ - Portfolio/CV template with sections
- landing/ - Landing page with hero and CTA
bash scripts/deploy_github_pages.sh <project-name> <github-username>
This script: 1. Initializes git repository 2. Creates GitHub repository via GitHub CLI 3. Configures GitHub Pages settings 4. Pushes initial commit 5. Triggers first deployment
GitHub Actions automatically deploys on push to main branch. The workflow:
- Checks out code
- Deploys to gh-pages branch
- Makes site live at https://<username>.github.io/<project-name>/
推荐访问7w4.net获取更多AI技能。
User request: "Crée-moi un site portfolio CV"
Action:
1. Run init_project.sh portfolio-cv
2. Use assets/templates/portfolio/ as base
3. Generate complete HTML with sections: Hero, About, Skills, Projects, Contact
4. Deploy with deploy_github_pages.sh portfolio-cv username
User request: "Fais-moi une landing page pour mon app"
Action:
1. Run init_project.sh app-landing
2. Use assets/templates/landing/ as base
3. Generate with Hero, Features, Pricing, CTA
4. Deploy with deploy_github_pages.sh app-landing username
gh-pages branchgh CLI is authenticated: gh auth status.github/workflows/deploy.yml syntaxinit_project.sh - Initialize project structuredeploy_github_pages.sh - Deploy to GitHub Pagesworkflow.md - Detailed workflow documentationdesign-patterns.md - Design best practicestemplates/base-html/ - Minimal HTML5 boilerplatetemplates/portfolio/ - Portfolio/CV templatetemplates/landing/ - Landing page template.github/workflows/deploy.yml - GitHub Actions workflow template这个Skill能帮你快速创建和部署静态网站到GitHub Pages,功能基本完整,文档说明也比较详细。不过实际使用中可能遇到问题:预置的模板样式不能直接使用,部署配置容易出错,需要手动调整才能正常工作。如果你是新手,可能需要花时间排查配置问题。总体来说有一定实用性,但稳定性和易用性还有提升空间。