# github-pages

Publish a static site on GitHub Pages (branch or Actions build), check it, and know when to use Cloudflare Pages instead (git-connected previews, custom domains on our Cloudflare zones).

- **Space:** github-ops-public (https://github.com/Tech-Realm/space-github-ops-public/tree/main/github-pages)
- **Level:** L1 (as the registry reports it)
- **Keys it needs (names only):** GITHUB_TOKEN
- **Tools:** gh, curl
- **Routes:** gh-cli; checks: 2
- **Uses:** new (no recorded use yet)
- **Install:** `logicpacks pack use github-ops-public/github-pages` or MCP `get_pack github-ops-public/github-pages`
- **Files:** CHANGELOG.md, code/enable_pages.sh, outcome/EVIDENCE.md, outcome/checks.yaml, outcome/results.json, pack.yaml, spec/SPEC.md, spec/source.md

## Purpose (spec/SPEC.md)

Publish a static site on GitHub Pages (branch or Actions build), check it, and know when to use Cloudflare Pages instead (git-connected previews, custom domains on our Cloudflare zones).

## Goal

A static demo or docs site live at <user>.github.io/<repo> (or a custom domain) with one command.

## Steps

1. Make sure the repo is public (Pages on private repos needs a paid plan) and Waleed approved making it public.
2. Enable from a branch: `gh api -X POST repos/<o>/<r>/pages -f 'source[branch]=main' -f 'source[path]=/'` (or `build_type=workflow` with actions/deploy-pages).
3. Wait for the build: `gh api repos/<o>/<r>/pages/builds/latest --jq .status` until `built`.
4. Check: `curl -fsS -o /dev/null -w '%{http_code}' https://<user>.github.io/<repo>/` = 200, and open it at 390px.
5. For sites on our domains with preview builds per branch, prefer Cloudflare Pages git-connected (see the cloudflare space).

## Edge cases

- Asset paths must be relative or include the /<repo>/ base path.
- No server code: static files only.

## Don'ts

- Don't publish private client work on Pages.



---

Canonical URL: https://logicpacks.io/packs/github-ops-public/github-pages

Developed by TechRealm (techrealm.online), the software team. Operated by Al Jash Trading (Establishment), Abu Dhabi, since 1994, the legal entity that hosts and is responsible for the service. Economic licence CN-1030597, Abu Dhabi Registration Authority. Address: Office 5, Bani Yas West 4, Bani Yas, Abu Dhabi, UAE. Website: https://aljashtrading.com. Contact: hello@logicpacks.io, security@logicpacks.io, WhatsApp +1 713 632 2262 (https://wa.me/17136322262).

Machine-readable index: [/llms.txt](/llms.txt). Plain facts: [/about.md](/about.md). Safety: [/safety.md](/safety.md).
