
Gh Pages Deploy
This automates GitHub Pages deployment through the gh CLI, handling the whole flow from repo creation to getting your site live. You get a one-shot script that initializes git, creates a public repo, enables Pages, and sets the homepage URL in one go. It's honestly the straightforward approach if you're already using gh CLI and just want to push static content without wrestling with Actions workflows or manual settings. Every push to main auto-deploys, which is clean for quick demos and prototypes. The skill includes the actual API calls to enable Pages programmatically, which saves you from clicking through the web UI every time.
- skills.sh installs
- 312
- GitHub stars
- 51
- last updated
- Aug 21, 2026
Install
$ npx -y skills add aviz85/claude-skills-library --skill gh-pages-deploy --agent claude-codeInstalls into .claude/skills of the current project.
Files
GitHub Pages Deployment
Deploy static frontend websites to GitHub Pages using the GitHub CLI.
Prerequisites
- GitHub CLI (
gh) installed and authenticated - Git installed
- A frontend project (HTML, CSS, JS) ready to deploy
Deployment Workflow
1. Initialize Git Repository (if needed)
git init
git add .
git commit -m "Initial commit"
2. Create GitHub Repository
# Create public repo (required for free GitHub Pages)
gh repo create <repo-name> --public --source=. --push
3. Enable GitHub Pages
# Enable GitHub Pages from main branch root
gh api repos/{owner}/{repo}/pages -X POST -f build_type=legacy -f source='{"branch":"main","path":"/"}'
Or for docs folder:
gh api repos/{owner}/{repo}/pages -X POST -f build_type=legacy -f source='{"branch":"main","path":"/docs"}'
4. Check Deployment Status
# Get pages info
gh api repos/{owner}/{repo}/pages
# View deployment status
gh api repos/{owner}/{repo}/pages/builds/latest
5. Set Homepage URL in Repo Settings
Always do this — sets the live URL in the GitHub repo's About panel (top-right on the repo page):
Sponsors
Details
- Repository
- github.com/aviz85/claude-skills-library
- Categories
- Frontend Development, DevOps & CI/CD, Git & Pull Requests, Documentation, Release Management, Automation & Workflows, CLI & Terminal
- First seen
- Jun 3, 2026