{"id":"dcef1f1d-9a33-4eef-91f2-2e55a8e2d603","slug":"publish-to-pages","kind":"skill","name":"publish-to-pages","summary":"Publish presentations and web content to GitHub Pages. Converts PPTX, PDF, HTML, or Google Slides to a live GitHub Pages URL. Handles repo creation, file conversion, Pages enablement, and returns the","owner":"github","repoUrl":"https://github.com/github/awesome-copilot/tree/HEAD/skills/publish-to-pages","license":"MIT","licenseTier":"permissive","trust":"official","stars":39994,"match":null,"fewStars":false,"format":"skill","createdAt":null,"addedAt":"2026-10-14T05:16:36.484Z","logoUrl":"https://avatars.githubusercontent.com/u/9919?v=4","linkOnly":false,"collection":{"name":"awesome-copilot","repo":"github/awesome-copilot"},"skillPath":"skills/publish-to-pages","categories":["developer-tools","files-documents","browser-web"],"tags":["ai","github-copilot","prompt-engineering","hacktoberfest","agents","awesome","custom-agents"],"runtime":"binary","local":true,"cloudCapable":false,"cloudCapability":"unknown","cloudReadyOnPlatform":false,"needsApiKey":false,"reviewed":false,"syncedAt":"2026-10-14T05:16:36.482Z","sample":false,"url":"https://conduits.dev/tools/publish-to-pages","language":"JavaScript","transports":[],"install":{},"requirements":{"env":[],"upstreamMayCharge":false},"tools":null,"readme":"> Publish presentations and web content to GitHub Pages. Converts PPTX, PDF, HTML, or Google Slides to a live GitHub Pages URL. Handles repo creation, file conversion, Pages enablement, and returns the live URL. Use when the user wants to publish, deploy, or share a presentation or HTML file via GitHub Pages.\n\n# publish-to-pages\n\nPublish any presentation or web content to GitHub Pages in one shot.\n\n## 1. Prerequisites Check\n\nRun these silently. Only surface errors:\n\n```bash\ncommand -v gh >/dev/null || echo \"MISSING: gh CLI — install from https://cli.github.com\"\ngh auth status &>/dev/null || echo \"MISSING: gh not authenticated — run 'gh auth login'\"\ncommand -v python3 >/dev/null || echo \"MISSING: python3 (needed for PPTX conversion)\"\n```\n\n`poppler-utils` is optional (PDF conversion via `pdftoppm`). Don't block on it.\n\n## 2. Input Detection\n\nDetermine input type from what the user provides:\n\n| Input | Detection |\n|-------|-----------|\n| HTML file | Extension `.html` or `.htm` |\n| PPTX file | Extension `.pptx` |\n| PDF file | Extension `.pdf` |\n| Google Slides URL | URL contains `docs.google.com/presentation` |\n\nAsk the user for a **repo name** if not provided. Default: filename without extension.\n\n## 3. Conversion\n\n### Large File Handling\n\nBoth conversion scripts automatically detect large files and switch to **external assets mode**:\n- **PPTX:** Files >20MB or with >50 images → images saved as separate files in `assets/`\n- **PDF:** Files >20MB or with >50 pages → page PNGs saved in `assets/`\n- Files >150MB print a warning (PPTX suggests PDF path instead)\n\nThis keeps individual files well under GitHub's 100MB limit. Small files still produce a single self-contained HTML.\n\nYou can force the behavior with `--external-assets` or `--no-external-assets`.\n\n### HTML\nNo conversion needed. Use the file directly as `index.html`.\n\n### PPTX\nRun the conversion script:\n```bash\npython3 SKILL_DIR/scripts/convert-pptx.py INPUT_FILE /tmp/output.html\n# For large files, force external assets:\npython3 SKILL_DIR/scripts/convert-pptx.py INPUT_FILE /tmp/output.html --external-assets\n```\nIf `python-pptx` is missing, tell the user: `pip install python-pptx`\n\n### PDF\nConvert with the included script (requires `poppler-utils` for `pdftoppm`):\n```bash\npython3 SKILL_DIR/scripts/convert-pdf.py INPUT_FILE /tmp/output.html\n# For large files, force external assets:\npython3 SKILL_DIR/scripts/convert-pdf.py INPUT_FILE /tmp/output.html --external-assets\n```\nEach page is rendered as a PNG and embedded into HTML with slide navigation.\nIf `pdftoppm` is missing, tell the user: `apt install poppler-utils` (or `brew install poppler` on macOS).\n\n### Google Slides\n1. Extract the presentation ID from the URL (the long string between `/d/` and `/`)\n2. Download as PPTX:\n```bash\ncurl -L \"https://docs.google.com/presentation/d/PRESENTATION_ID/export/pptx\" -o /tmp/slides.pptx\n```\n3. Then convert the PPTX using the convert script above.\n\n## 4. Publishing\n\n### Visibility\nRepos are created **public** by default. If the user specifies `private` (or wants a private repo), use `--private` — but note that GitHub Pages on private repos requires a Pro, Team, or Enterprise plan.\n\n### Publish\n```bash\nbash SKILL_DIR/scripts/publish.sh /path/to/index.html REPO_NAME public \"Description\"\n```\n\nPass `private` instead of `public` if the user requests it.\n\nThe script creates the repo, pushes `index.html` (plus `assets/` if present), and enables GitHub Pages.\n\n**Note:** When external assets mode is used, the output HTML references files in `assets/`. The publish script automatically detects and copies the `assets/` directory alongside the HTML file. Make sure the HTML file and its `assets/` directory are in the same parent directory.\n\n## 5. Output\n\nTell the user:\n- **Repository:** `https://github.com/USERNAME/REPO_NAME`\n- **Live URL:** `https://USERNAME.github.io/REPO_NAME/`\n- **Note:** Pages takes 1-2 minutes to go live.\n\n## Error Handling\n\n- **Repo already exists:** Suggest appending a number (`my-slides-2`) or a date (`my-slides-2026`).\n- **Pages enablement fails:** Still return the repo URL. User can enable Pages manually in repo Settings.\n- **PPTX conversion fails:** Tell user to run `pip install python-pptx`.\n- **PDF conversion fails:** Suggest installing `poppler-utils` (`apt install poppler-utils` or `brew install poppler`).\n- **Google Slides download fails:** The presentation may not be publicly accessible. Ask user to make it viewable or download the PPTX manually."}